https://gcc.gnu.org/bugzilla/show_bug.cgi?id=128925

            Bug ID: 128925
           Summary: ICE in reshape_init_class, at cp/decl.cc with
                    -std=c++29
           Product: gcc
           Version: 17.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: s.kimura.h41104 at gmail dot com
  Target Milestone: ---

Compiler Explorer: https://godbolt.org/z/Wrjno1aGP

Reproducer:
```
struct S1 {
  int s1;
};
struct S2 : S1 {};
struct S3 : S2 {};
constexpr auto L = S3{.s1 = 1, .s2 = 2};
```

Backtrace:
<source>:6:39: internal compiler error: in reshape_init_class, at
cp/decl.cc:8081
    6 | constexpr auto L = S3{.s1 = 1, .s2 = 2};
      |                                       ^
0x2d34b48 diagnostics::context::diagnostic_impl(rich_location*,
diagnostics::metadata const*, diagnostics::option_id, char const*,
__va_list_tag (*) [1], diagnostics::kind)
        ???:0
0x2d2978b internal_error(char const*, ...)
        ???:0
0xc23478 fancy_abort(char const*, int, char const*)
        ???:0
0xd33f64 reshape_init(tree_node*, tree_node*, int)
        ???:0
0xf222f3 finish_compound_literal(tree_node*, tree_node*, int, fcl_t)
        ???:0
0xe80253 c_parse_file()
        ???:0
0x1016be9 c_common_parse_file()
        ???:0

Reply via email to