Bug 125989 - [C++29] P2287R6, Designated-initializers for Base Classes
Summary: [C++29] P2287R6, Designated-initializers for Base Classes
Status: ASSIGNED
Alias: None
Product: gcc
Classification: Unclassified
Component: c++ (show other bugs)
Version: 17.0
: P3 normal
Target Milestone: ---
Assignee: Jakub Jelinek
URL:
Keywords: c++29
Depends on:
Blocks: c++29-core
  Show dependency treegraph
 
Reported: 2026-06-25 17:36 UTC by Jakub Jelinek
Modified: 2026-07-17 20:12 UTC (History)
2 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2026-06-25 00:00:00


Attachments
gcc17-pr125989-wip.patch (4.62 KB, patch)
2026-07-17 18:40 UTC, Jakub Jelinek
Details | Diff
gcc17-pr125989-wip.patch (4.66 KB, patch)
2026-07-17 20:12 UTC, Jakub Jelinek
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jakub Jelinek 2026-06-25 17:36:14 UTC
See <https://wg21.link/P2287R6>.
Comment 1 Drea Pinski 2026-06-25 17:46:25 UTC
.
Comment 2 Jakub Jelinek 2026-07-17 18:40:53 UTC
Created attachment 65076 [details]
gcc17-pr125989-wip.patch

Current untested WIP.  There is one case in desig8.C I still need to look at, more testcase coverage (the current one is basically all the examples in the paper and nothing else) and decide what to do about the GNU [0] = designators vs. the new designator-initializer-list vs. designator-only-initializer-list, i.e. whether we allow { 1, [2] = 2 } or not and if we don't allow it, where do we reject it for C++29.
Comment 3 Jakub Jelinek 2026-07-17 20:12:42 UTC
Created attachment 65077 [details]
gcc17-pr125989-wip.patch

Updated patch, still need to extend testsuite, but the rest mentioned above should be changed.