On Tue, Feb 13, 2024 at 02:43:39PM -0500, Marek Polacek wrote:
> On Tue, Feb 13, 2024 at 08:38:18PM +0100, Jakub Jelinek wrote:
> > On Tue, Feb 13, 2024 at 02:24:11PM -0500, Marek Polacek wrote:
> > > Sadly, I must admit this is looking like GCC 15 material.
> > 
> > If deferred for GCC 15, can't we at least do some minimal
> > change and just guard the member pedwarn with cxx_dialect < something?
> 
> I could do something like that, but...
> 
> > Given that -Wextra-semi isn't on by default nor included in
> > -Wall -W, I think even accepting this for GCC 14 wouldn't be that
> > risky.
> 
> ...I also don't think it's that risky but technically, it's not
> a regression I think.
>  
> > Jason's decision.
> > 
> > +      /* If -Wextra-semi wasn't specified, warn only when -pedantic is in  
> >                                                                             
> >                               
> > +        effect in C++11 and below.  DR 1693 added "empty-declaration" to 
> > the                                                                         
> >                                 
> > +        syntax for "member-declaration".  */                               
> >                                                                             
> >                               
> > +      else if (pedantic && cxx_dialect < cxx14)                            
> >                                                                             
> >                               
> > 
> > If it was a DR, did it apply just to C++14 or changed C++11 as well?
> 
> It's got Status: C++14 so I thought that C++11/C++98 had not been
> adjusted. 

...but then so was DR 1601 which I implemented in 
https://gcc.gnu.org/git/?p=gcc.git&a=commit;h=e295e3d981355c61b72eca2ee58864958655cc31
and made it apply to C++11 as well.

So I'm starting to lean towards adjusting this patch to
make DR 1693 apply to C++11 as well, but not C++98.  Probably
not a very important distinction in practice though.

Marek

Reply via email to