[Bug c++/100489] [10/11/12 Regression] ICE in cp/constexpr.c:3556
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100489 Jason Merrill changed: What|Removed |Added Resolution|--- |FIXED Status|ASSIGNED|RESOLVED --- Comment #5 from Jason Merrill --- Fixed for 10.4/11.2/12.
[Bug c++/100489] [10/11/12 Regression] ICE in cp/constexpr.c:3556
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100489 --- Comment #4 from CVS Commits --- The releases/gcc-10 branch has been updated by Jason Merrill : https://gcc.gnu.org/g:a335afe208cd27cf8ee4cb028fb7769700ab6245 commit r10-9857-ga335afe208cd27cf8ee4cb028fb7769700ab6245 Author: Jason Merrill Date: Wed May 19 21:12:45 2021 -0400 c++: designated init with anonymous union [PR100489] My patch for PR98463 added an assert that tripped on this testcase, because we ended up with a U CONSTRUCTOR with an initializer for a, which is not a member of U. We need to wrap the a initializer in another CONSTRUCTOR for the anonymous union. For the GCC 10 branch, just remove the assert. PR c++/100489 gcc/cp/ChangeLog: * constexpr.c (get_or_insert_ctor_field): Remove assert. gcc/testsuite/ChangeLog: * g++.dg/cpp2a/desig18.C: New test.
[Bug c++/100489] [10/11/12 Regression] ICE in cp/constexpr.c:3556
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100489 --- Comment #3 from CVS Commits --- The releases/gcc-11 branch has been updated by Jason Merrill : https://gcc.gnu.org/g:0a1010428b3861464eb319c629c68cb13b9ca01e commit r11-8449-g0a1010428b3861464eb319c629c68cb13b9ca01e Author: Jason Merrill Date: Wed May 19 21:12:45 2021 -0400 c++: designated init with anonymous union [PR100489] My patch for PR98463 added an assert that tripped on this testcase, because we ended up with a U CONSTRUCTOR with an initializer for a, which is not a member of U. We need to wrap the a initializer in another CONSTRUCTOR for the anonymous union. There was already support for this in process_init_constructor_record, but not in process_init_constructor_union. But since this is about brace elision, it really belongs under reshape_init rather than digest_init, so this patch moves the handling to reshape_init_class, which also handles unions. PR c++/100489 gcc/cp/ChangeLog: * decl.c (reshape_init_class): Handle designator for member of anonymous aggregate here. * typeck2.c (process_init_constructor_record): Not here. gcc/testsuite/ChangeLog: * g++.dg/cpp2a/desig18.C: New test.
[Bug c++/100489] [10/11/12 Regression] ICE in cp/constexpr.c:3556
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100489 --- Comment #2 from CVS Commits --- The master branch has been updated by Jason Merrill : https://gcc.gnu.org/g:84fd1b5dff70cd74aee7e8b18f66959d8b8e1ce7 commit r12-954-g84fd1b5dff70cd74aee7e8b18f66959d8b8e1ce7 Author: Jason Merrill Date: Wed May 19 21:12:45 2021 -0400 c++: designated init with anonymous union [PR100489] My patch for PR98463 added an assert that tripped on this testcase, because we ended up with a U CONSTRUCTOR with an initializer for a, which is not a member of U. We need to wrap the a initializer in another CONSTRUCTOR for the anonymous union. There was already support for this in process_init_constructor_record, but not in process_init_constructor_union. But since this is about brace elision, it really belongs under reshape_init rather than digest_init, so this patch moves the handling to reshape_init_class, which also handles unions. PR c++/100489 gcc/cp/ChangeLog: * decl.c (reshape_init_class): Handle designator for member of anonymous aggregate here. * typeck2.c (process_init_constructor_record): Not here. gcc/testsuite/ChangeLog: * g++.dg/cpp2a/desig18.C: New test.
[Bug c++/100489] [10/11/12 Regression] ICE in cp/constexpr.c:3556
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100489 Jason Merrill changed: What|Removed |Added CC||jason at gcc dot gnu.org Assignee|unassigned at gcc dot gnu.org |jason at gcc dot gnu.org Status|NEW |ASSIGNED
[Bug c++/100489] [10/11/12 Regression] ICE in cp/constexpr.c:3556
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100489 Richard Biener changed: What|Removed |Added Target Milestone|--- |10.4 Known to work||10.2.0, 10.3.0 Summary|[10.3/11/12 REGRESSION] ICE |[10/11/12 Regression] ICE |in cp/constexpr.c:3556 |in cp/constexpr.c:3556 Priority|P3 |P2 Keywords||ice-on-valid-code