Re: [PATCH] c++: Reject anonymous struct with bases

2021-07-31 Thread Jason Merrill via Gcc-patches
On Fri, Jul 30, 2021 at 3:35 PM Andrew Pinski wrote: > On Fri, Jul 30, 2021 at 9:26 AM Jason Merrill via Gcc-patches > wrote: > > > > In discussion of jakub's patch for C++20 pointer-interconvertibility, it > > came up that we allow anonymous structs to have bases, but don't do > anything > > us

Re: [PATCH] c++: Reject anonymous struct with bases

2021-07-30 Thread Andrew Pinski via Gcc-patches
On Fri, Jul 30, 2021 at 9:26 AM Jason Merrill via Gcc-patches wrote: > > In discussion of jakub's patch for C++20 pointer-interconvertibility, it > came up that we allow anonymous structs to have bases, but don't do anything > usable with them. Let's reject it. > > The comment change is something

[PATCH] c++: Reject anonymous struct with bases

2021-07-30 Thread Jason Merrill via Gcc-patches
In discussion of jakub's patch for C++20 pointer-interconvertibility, it came up that we allow anonymous structs to have bases, but don't do anything usable with them. Let's reject it. The comment change is something I noticed while looking for the right place to diagnose this: finish_struct_anon