PR c++/16112
* cp-gimplify.c (cp_gimplify_init_expr): Look through
CLEANUP_POINT_EXPR.
From-SVN: r83514
+2004-06-21 Jason Merrill <jason@redhat.com>
+
+ * cp-gimplify.c (cp_gimplify_init_expr): Look throug
+
2004-06-21 Mark Mitchell <mark@codesourcery.com>
* cp-tree.def (NEW_EXPR): Add a fourth slot.
case, I guess we'll need to replace references somehow. */
if (TREE_CODE (from) == TARGET_EXPR)
from = TARGET_EXPR_INITIAL (from);
+ if (TREE_CODE (from) == CLEANUP_POINT_EXPR)
+ from = TREE_OPERAND (from, 0);
/* Look through any COMPOUND_EXPRs. */
sub = expr_last (from);
--- /dev/null
+// PR c++/16112
+// { dg-options "" }
+
+struct A
+{
+ A();
+};
+
+A foo() { return ({ A(); }); }