Re: [PATCH] c++: broken direct-init with trailing array member [PR114439]

2024-03-25 Thread Jason Merrill
On 3/25/24 17:59, Marek Polacek wrote: Bootstrapped/regtested on x86_64-pc-linux-gnu, ok for trunk? OK. -- >8 -- can_init_array_with_p is wrongly saying that the init for 's' here: struct S { int *list = arr; int arr[]; }; struct A { A() {} S s[2]{}; }; is i

[PATCH] c++: broken direct-init with trailing array member [PR114439]

2024-03-25 Thread Marek Polacek
Bootstrapped/regtested on x86_64-pc-linux-gnu, ok for trunk? -- >8 -- can_init_array_with_p is wrongly saying that the init for 's' here: struct S { int *list = arr; int arr[]; }; struct A { A() {} S s[2]{}; }; is invalid. But as process_init_constructor_array says, for