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

--- Comment #12 from Stephan Bergmann <sbergman at redhat dot com> ---
(In reply to CVS Commits from comment #11)
> The master branch has been updated by Jason Merrill <ja...@gcc.gnu.org>:
> 
> https://gcc.gnu.org/g:81bec060e31b6ef2feeb3046c6f13a207c6f698a
> 
> commit r13-1559-g81bec060e31b6ef2feeb3046c6f13a207c6f698a
> Author: Jason Merrill <ja...@redhat.com>
> Date:   Thu Jul 7 10:12:04 2022 -0400
> 
>     c++: -Woverloaded-virtual and dtors [PR87729]

This still starts to produces spurious warnings for diamond inheritance:

> $ cat test.cc
> struct S1 { virtual void f(); };
> struct S2: S1 {};
> struct S3: S1 {};
> struct S4: S2, S3 { void f(); };

> $ g++ -Woverloaded-virtual -fsyntax-only test.cc
> test.cc:1:26: warning: ‘virtual void S1::f()’ was hidden 
> [-Woverloaded-virtual=]
>     1 | struct S1 { virtual void f(); };
>       |                          ^
> test.cc:4:26: note:   by ‘virtual void S4::f()’
>     4 | struct S4: S2, S3 { void f(); };
>       |                          ^

Reply via email to