Commit 236fd18c by Jason Merrill Committed by Jason Merrill

* tree.c (build_cplus_new): Handle CONSTRUCTOR.

From-SVN: r166007
parent e02927a1
2010-10-27 Jason Merrill <jason@redhat.com>
* tree.c (build_cplus_new): Handle CONSTRUCTOR.
* semantics.c (finish_compound_stmt): Avoid creating an
unnecessary BIND_EXPR.
......
......@@ -441,7 +441,8 @@ build_cplus_new (tree type, tree init)
if (TREE_CODE (rval) == AGGR_INIT_EXPR)
slot = AGGR_INIT_EXPR_SLOT (rval);
else if (TREE_CODE (rval) == CALL_EXPR)
else if (TREE_CODE (rval) == CALL_EXPR
|| TREE_CODE (rval) == CONSTRUCTOR)
slot = build_local_temp (type);
else
return rval;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment