aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/typeck2.c
diff options
context:
space:
mode:
authormsebor <msebor@138bc75d-0d04-0410-961f-82ee72b054a4>2016-04-14 17:35:23 +0000
committermsebor <msebor@138bc75d-0d04-0410-961f-82ee72b054a4>2016-04-14 17:35:23 +0000
commit4c1007f11e4c4ff880b06488b10117c36c46238e (patch)
tree83cb3798bea28b1aa1cc72277814a9f1a15bffd0 /gcc/cp/typeck2.c
parent22dcab66b8b4cb3ce61637474e8fcc6bd9dd2b30 (diff)
PR c++/70652 - [6 Regression] r234966 causes bootstrap to fail
Revert patch for c++/69517, c++/70019, and c++/70588. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@234981 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/cp/typeck2.c')
-rw-r--r--gcc/cp/typeck2.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/cp/typeck2.c b/gcc/cp/typeck2.c
index eba19ca11ac..b921689808a 100644
--- a/gcc/cp/typeck2.c
+++ b/gcc/cp/typeck2.c
@@ -603,7 +603,7 @@ split_nonconstant_init_1 (tree dest, tree init)
array_type_p = true;
if ((TREE_SIDE_EFFECTS (init)
&& TYPE_HAS_NONTRIVIAL_DESTRUCTOR (type))
- || variably_modified_type_p (type, NULL_TREE))
+ || array_of_runtime_bound_p (type))
{
/* For an array, we only need/want a single cleanup region rather
than one per element. */
@@ -845,7 +845,7 @@ store_init_value (tree decl, tree init, vec<tree, va_gc>** cleanups, int flags)
will perform the dynamic initialization. */
if (value != error_mark_node
&& (TREE_SIDE_EFFECTS (value)
- || variably_modified_type_p (type, NULL_TREE)
+ || array_of_runtime_bound_p (type)
|| ! reduced_constant_expression_p (value)))
return split_nonconstant_init (decl, value);
/* If the value is a constant, just put it in DECL_INITIAL. If DECL