Message ID | alpine.LSU.2.20.1702021014580.12993@r111.fhfr.qr |
---|---|
State | New |
Headers | show |
Index: gcc/cp/constexpr.c =================================================================== --- gcc/cp/constexpr.c (revision 245119) +++ gcc/cp/constexpr.c (working copy) @@ -4916,6 +4919,8 @@ maybe_constant_init (tree t, tree decl) t = TARGET_EXPR_INITIAL (t); if (!potential_nondependent_static_init_expression (t)) /* Don't try to evaluate it. */; + else if (CONSTANT_CLASS_P (t)) + return t; else t = cxx_eval_outermost_constant_expr (t, true, false, decl); if (TREE_CODE (t) == TARGET_EXPR)