[Bug c++/105925] [11/12/13 Regression] Could not convert '{{0, 0.0}}' from '' to 'X' since r12-954-g84fd1b5dff70cd74
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105925 Jason Merrill changed: What|Removed |Added Status|ASSIGNED|RESOLVED Resolution|--- |FIXED Known to work||11.3.1, 12.1.1, 13.0 --- Comment #8 from Jason Merrill --- Fixed for 11.4/12.2/13.
[Bug c++/105925] [11/12/13 Regression] Could not convert '{{0, 0.0}}' from '' to 'X' since r12-954-g84fd1b5dff70cd74
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105925 --- Comment #7 from CVS Commits --- The releases/gcc-11 branch has been updated by Jason Merrill : https://gcc.gnu.org/g:553aecc570ce4ef5c751dc39b83bfbde6380f953 commit r11-10091-g553aecc570ce4ef5c751dc39b83bfbde6380f953 Author: Jason Merrill Date: Thu Jun 23 16:04:02 2022 -0400 c++: anon union designated init [PR105925] This testcase was failing because CONSTRUCTOR_IS_DESIGNATED_INIT wasn't getting set on the introduced CONSTRUCTOR for the anonymous union, and build_aggr_conv uses that flag to decide whether to pay attention to the indexes of the CONSTRUCTOR. So set the flag when we see a designator rather than relying on copying it from another CONSTRUCTOR. PR c++/105925 gcc/cp/ChangeLog: * decl.c (reshape_init_array_1): Set CONSTRUCTOR_IS_DESIGNATED_INIT here. (reshape_init_class): And here. gcc/testsuite/ChangeLog: * g++.dg/cpp2a/desig26.C: New test.
[Bug c++/105925] [11/12/13 Regression] Could not convert '{{0, 0.0}}' from '' to 'X' since r12-954-g84fd1b5dff70cd74
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105925 --- Comment #6 from CVS Commits --- The releases/gcc-12 branch has been updated by Jason Merrill : https://gcc.gnu.org/g:db29b66193407d2fd6a04a07ecbd961c8d3f7d62 commit r12-8511-gdb29b66193407d2fd6a04a07ecbd961c8d3f7d62 Author: Jason Merrill Date: Thu Jun 23 16:04:02 2022 -0400 c++: anon union designated init [PR105925] This testcase was failing because CONSTRUCTOR_IS_DESIGNATED_INIT wasn't getting set on the introduced CONSTRUCTOR for the anonymous union, and build_aggr_conv uses that flag to decide whether to pay attention to the indexes of the CONSTRUCTOR. So set the flag when we see a designator rather than relying on copying it from another CONSTRUCTOR. PR c++/105925 gcc/cp/ChangeLog: * decl.cc (reshape_init_array_1): Set CONSTRUCTOR_IS_DESIGNATED_INIT here. (reshape_init_class): And here. gcc/testsuite/ChangeLog: * g++.dg/cpp2a/desig26.C: New test.
[Bug c++/105925] [11/12/13 Regression] Could not convert '{{0, 0.0}}' from '' to 'X' since r12-954-g84fd1b5dff70cd74
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105925 --- Comment #5 from CVS Commits --- The master branch has been updated by Jason Merrill : https://gcc.gnu.org/g:6c72f1bfc3469422460d86314a081353632d4bcb commit r13-1227-g6c72f1bfc3469422460d86314a081353632d4bcb Author: Jason Merrill Date: Thu Jun 23 14:41:19 2022 -0400 c++: designated init cleanup [PR105925] build_aggr_conv expects to run after reshape_init, which will usually have filled out all the CONSTRUCTOR indexes; there's no reason to limit using those to the case where the user gave an explicit designator. PR c++/105925 gcc/cp/ChangeLog: * call.cc (build_aggr_conv): Don't depend on CONSTRUCTOR_IS_DESIGNATED_INIT.
[Bug c++/105925] [11/12/13 Regression] Could not convert '{{0, 0.0}}' from '' to 'X' since r12-954-g84fd1b5dff70cd74
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105925 --- Comment #4 from CVS Commits --- The master branch has been updated by Jason Merrill : https://gcc.gnu.org/g:d610ae121e8ecd738de4dc01e6ac11ecf7c2327e commit r13-1226-gd610ae121e8ecd738de4dc01e6ac11ecf7c2327e Author: Jason Merrill Date: Thu Jun 23 16:04:02 2022 -0400 c++: anon union designated init [PR105925] This testcase was failing because CONSTRUCTOR_IS_DESIGNATED_INIT wasn't getting set on the introduced CONSTRUCTOR for the anonymous union, and build_aggr_conv uses that flag to decide whether to pay attention to the indexes of the CONSTRUCTOR. So set the flag when we see a designator rather than relying on copying it from another CONSTRUCTOR. This avoids some redundant errors on desig4.C because we stop setting CONSTRUCTOR_IS_DESIGNATED_INIT on _Complex CONSTRUCTORs where it's nonsense. PR c++/105925 gcc/cp/ChangeLog: * decl.cc (reshape_init_array_1): Set CONSTRUCTOR_IS_DESIGNATED_INIT here. (reshape_init_class): And here. (reshape_init): Not here. gcc/testsuite/ChangeLog: * g++.dg/ext/desig4.C: Remove extra errors. * g++.dg/cpp2a/desig26.C: New test.
[Bug c++/105925] [11/12/13 Regression] Could not convert '{{0, 0.0}}' from '' to 'X' since r12-954-g84fd1b5dff70cd74
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105925 Jason Merrill changed: What|Removed |Added Status|NEW |ASSIGNED Assignee|unassigned at gcc dot gnu.org |jason at gcc dot gnu.org
[Bug c++/105925] [11/12/13 Regression] Could not convert '{{0, 0.0}}' from '' to 'X' since r12-954-g84fd1b5dff70cd74
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105925 Martin Liška changed: What|Removed |Added Summary|[11/12/13 Regression] Could |[11/12/13 Regression] Could |not convert '{{0, 0.0}}'|not convert '{{0, 0.0}}' |from '' to 'X' |initializer list>' to 'X' ||since ||r12-954-g84fd1b5dff70cd74 Keywords|needs-bisection | CC||jason at gcc dot gnu.org --- Comment #3 from Martin Liška --- Started with r12-954-g84fd1b5dff70cd74.