This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/69253] [6 Regression] ICE in cxx_incomplete_type_diagnostic initializing a flexible array member with empty string
- From: "msebor at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 04 Feb 2016 04:51:14 +0000
- Subject: [Bug c++/69253] [6 Regression] ICE in cxx_incomplete_type_diagnostic initializing a flexible array member with empty string
- Auto-submitted: auto-generated
- References: <bug-69253-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69253
--- Comment #5 from Martin Sebor <msebor at gcc dot gnu.org> ---
Author: msebor
Date: Thu Feb 4 04:50:42 2016
New Revision: 233126
URL: https://gcc.gnu.org/viewcvs?rev=233126&root=gcc&view=rev
Log:
PR c++/69251 - [6 Regression] ICE in unify_array_domain on a flexible array
member
PR c++/69253 - [6 Regression] ICE in cxx_incomplete_type_diagnostic
initializing
a flexible array member with empty string
PR c++/69290 - [6 Regression] ICE on invalid initialization of a flexible array
member
PR c++/69277 - [6 Regression] ICE mangling a flexible array member
PR c++/69349 - template substitution error for flexible array members
gcc/testsuite/ChangeLog:
2016-02-03 Martin Sebor <msebor@redhat.com>
PR c++/69251
PR c++/69253
PR c++/69290
PR c++/69277
PR c++/69349
* g++.dg/ext/flexarray-mangle-2.C: New test.
* g++.dg/ext/flexarray-mangle.C: New test.
* g++.dg/ext/flexarray-subst.C: New test.
* g++.dg/ext/flexary11.C: New test.
* g++.dg/ext/flexary12.C: New test.
* g++.dg/ext/flexary13.C: New test.
* g++.dg/ext/flexary14.C: New test.
* g++.dg/other/dump-ada-spec-2.C: Adjust.
gcc/cp/ChangeLog:
2016-02-03 Martain Sebor <msebor@redhat.com>
PR c++/69251
PR c++/69253
PR c++/69290
PR c++/69277
PR c++/69349
* class.c (walk_subobject_offsets): Avoid testing the upper bound
of a flexible array member for equality to null.
(find_flexarrays): Remove spurious whitespace introduced in r231665.
(diagnose_flexarrays): Avoid checking the upper bound of arrays.
(check_flexarrays): Same.
* decl.c (compute_array_index_type): Avoid special case for flexible
array members.
(grokdeclarator): Avoid calling compute_array_index_type for flexible
array members.
* error.c (dump_type_suffix): Revert changes introduced in r231665
and rendered unnecessary by the changes above.
* pt.c (tsubst): Same.
* tree.c (build_ctor_subob_ref): Handle flexible array members.
* typeck2.c (digest_init_r): Revert changes introduced in r231665.
(process_init_constructor_array): Same.
(process_init_constructor_record): Same.
Added:
trunk/gcc/testsuite/g++.dg/ext/flexarray-mangle-2.C
trunk/gcc/testsuite/g++.dg/ext/flexarray-mangle.C
trunk/gcc/testsuite/g++.dg/ext/flexarray-subst.C
trunk/gcc/testsuite/g++.dg/ext/flexary11.C
trunk/gcc/testsuite/g++.dg/ext/flexary12.C
trunk/gcc/testsuite/g++.dg/ext/flexary13.C
trunk/gcc/testsuite/g++.dg/ext/flexary14.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/class.c
trunk/gcc/cp/decl.c
trunk/gcc/cp/error.c
trunk/gcc/cp/mangle.c
trunk/gcc/cp/pt.c
trunk/gcc/cp/tree.c
trunk/gcc/cp/typeck2.c
trunk/gcc/testsuite/ChangeLog
trunk/gcc/testsuite/g++.dg/other/dump-ada-spec-2.C