Commit 070d3be3 by Mark Mitchell Committed by Mark Mitchell

parse.y (new_initializer): Make sure all initializers are lists.

	* parse.y (new_initializer): Make sure all initializers are
	lists.

From-SVN: r18471
parent a8aa4e0b
Wed Mar 11 07:25:20 1998 Mark Mitchell <mmitchell@usa.net>
* parse.y (new_initializer): Make sure all initializers are
lists.
Tue Mar 10 07:32:36 1998 Mark Mitchell <mmitchell@usa.net> Tue Mar 10 07:32:36 1998 Mark Mitchell <mmitchell@usa.net>
* decl2.c (import_export_decl): Mark tinfo functions for * decl2.c (import_export_decl): Mark tinfo functions for
......
...@@ -1217,7 +1217,10 @@ new_initializer: ...@@ -1217,7 +1217,10 @@ new_initializer:
{ {
if (pedantic) if (pedantic)
pedwarn ("ANSI C++ forbids initialization of new expression with `='"); pedwarn ("ANSI C++ forbids initialization of new expression with `='");
$$ = $2; if (TREE_CODE ($2) != TREE_LIST)
$$ = build_expr_list (NULL_TREE, $2);
else
$$ = $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