PR103936 demonstrates that some VEC_INIT_EXPR can still survive into
GENERIC; until that's fixed let's put back the handling in cp_gimplify_expr.
PR c++/103936
PR c++/65591
gcc/cp/ChangeLog:
* cp-gimplify.c (cp_gimplify_expr): Restore VEC_INIT_EXPR handling.
gcc/testsuite/ChangeLog:
* g++.dg/init/aggr15.C: New test.
ret = GS_OK;
break;
+ case VEC_INIT_EXPR:
+ {
+ *expr_p = expand_vec_init_expr (NULL_TREE, *expr_p,
+ tf_warning_or_error);
+
+ hash_set<tree> pset;
+ cp_walk_tree (expr_p, cp_fold_r, &pset, NULL);
+ cp_genericize_tree (expr_p, false);
+ copy_if_shared (expr_p);
+ ret = GS_OK;
+ }
+ break;
+
case THROW_EXPR:
/* FIXME communicate throw type to back end, probably by moving
THROW_EXPR into ../tree.def. */
--- /dev/null
+// PR c++/65591
+
+struct ss {
+ ss() {};
+};
+struct C {
+ ss s[1000];
+};
+int main() {
+ C cs[5] = {};
+}