mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-03-20 12:41:17 +08:00
* semantics.c (finish_compound_literal): Set TREE_HAS_CONSTRUCTOR.
From-SVN: r174881
This commit is contained in:
parent
3d223145a5
commit
8c53f5e2fa
@ -1,3 +1,7 @@
|
||||
2011-06-09 Jason Merrill <jason@redhat.com>
|
||||
|
||||
* semantics.c (finish_compound_literal): Set TREE_HAS_CONSTRUCTOR.
|
||||
|
||||
2011-06-09 Paolo Carlini <paolo.carlini@oracle.com>
|
||||
|
||||
PR c++/29003
|
||||
|
@ -2387,6 +2387,8 @@ finish_compound_literal (tree type, tree compound_literal,
|
||||
return error_mark_node;
|
||||
}
|
||||
compound_literal = digest_init (type, compound_literal, complain);
|
||||
if (TREE_CODE (compound_literal) == CONSTRUCTOR)
|
||||
TREE_HAS_CONSTRUCTOR (compound_literal) = true;
|
||||
/* Put static/constant array temporaries in static variables, but always
|
||||
represent class temporaries with TARGET_EXPR so we elide copies. */
|
||||
if ((!at_function_scope_p () || CP_TYPE_CONST_P (type))
|
||||
|
Loading…
x
Reference in New Issue
Block a user