Commit 8b1616ad by Mark Mitchell Committed by Mark Mitchell

* parse.y: Deal with CONSTRUCTORS in new_initializers.

From-SVN: r18620
parent 66bd0128
Mon Mar 16 10:47:22 1998 Mark Mitchell <mmitchell@usa.net>
* parse.y: Deal with CONSTRUCTORS in new_initializers.
Mon Mar 16 10:54:21 1998 Mark Mitchell <mmitchell@usa.net> Mon Mar 16 10:54:21 1998 Mark Mitchell <mmitchell@usa.net>
* pt.c (tsubst_copy): Deal with BIND_EXPR in a way that more * pt.c (tsubst_copy): Deal with BIND_EXPR in a way that more
......
...@@ -1217,7 +1217,8 @@ new_initializer: ...@@ -1217,7 +1217,8 @@ new_initializer:
{ {
if (pedantic) if (pedantic)
pedwarn ("ANSI C++ forbids initialization of new expression with `='"); pedwarn ("ANSI C++ forbids initialization of new expression with `='");
if (TREE_CODE ($2) != TREE_LIST) if (TREE_CODE ($2) != TREE_LIST
&& TREE_CODE ($2) != CONSTRUCTOR)
$$ = build_expr_list (NULL_TREE, $2); $$ = build_expr_list (NULL_TREE, $2);
else else
$$ = $2; $$ = $2;
......
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