[Bug c++/86238] No diagnostic for virtual base class with inaccessible destructor
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86238 Jonathan Wakely changed: What|Removed |Added Keywords||accepts-invalid Summary|a vtable layout bug |No diagnostic for virtual ||base class with ||inaccessible destructor --- Comment #2 from Jonathan Wakely --- Please try to provide meaningful bug titles, and reduce the code to remove everything that isn't relevant. This bug reduces from a 72kB testcase to simply: struct s2 { ~s2() {} }; class s3 : virtual protected s2 { }; class s4 : private s3 { }; class s11 : s4 { } a11; C++ and EDG accept this, but Clang prints: test.cc:4:7: error: inherited virtual base class 's2' has private destructor class s11 : s4 { } a11; ^ test.cc:4:20: note: in implicit default constructor for 's11' first required here class s11 : s4 { } a11; ^ test.cc:3:12: note: constrained by private inheritance here class s4 : private s3 { }; ^~ test.cc:4:7: error: inherited virtual base class 's2' has private destructor class s11 : s4 { } a11; ^ test.cc:4:20: note: in implicit destructor for 's11' first required here class s11 : s4 { } a11; ^ test.cc:3:12: note: constrained by private inheritance here class s4 : private s3 { }; ^~ 2 errors generated.
[Bug c++/86238] No diagnostic for virtual base class with inaccessible destructor
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86238 Jonathan Wakely changed: What|Removed |Added Status|UNCONFIRMED |NEW Last reconfirmed||2018-06-21 Ever confirmed|0 |1
[Bug c++/86238] No diagnostic for virtual base class with inaccessible destructor
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86238 --- Comment #3 from Jonathan Wakely --- Simplified further: struct B { ~B() {} }; struct C : private virtual B {}; struct D : C {} d;
[Bug c++/86238] No diagnostic for virtual base class with inaccessible destructor
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86238 TC changed: What|Removed |Added CC||rs2740 at gmail dot com --- Comment #4 from TC --- Dup of bug 55120?
[Bug c++/86238] No diagnostic for virtual base class with inaccessible destructor
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86238 Andrew Pinski changed: What|Removed |Added Status|NEW |RESOLVED Resolution|--- |DUPLICATE --- Comment #5 from Andrew Pinski --- (In reply to TC from comment #4) > Dup of bug 55120? Yes. *** This bug has been marked as a duplicate of bug 55120 ***