https://gcc.gnu.org/bugzilla/show_bug.cgi?id=125151
--- Comment #4 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
And
struct A {
A () noexcept {}
virtual ~A ();
A (const A &);
A &operator= (const A &);
A (A &&);
A &operator= (A &&);
virtual const char *what ();
};
struct B : A {
B (int x) : b (x) {}
virtual ~B ();
B (const B &);
B &operator= (const B &);
B (B &&);
B &operator= (B &&);
virtual const char *what ();
int b;
};
A::~A () {}
A::A (const A &) = default;
A &A::operator= (const A &) = default;
A::A (A &&) = default;
A &A::operator= (A &&) = default;
const char *A::what () { return "A"; }
B::~B () {}
B::B (const B &) = default;
B &B::operator= (const B &) = default;
B::B (B &&) = default;
B &B::operator= (B &&) = default;
const char *B::what () { return "B"; }
on the libstdc++ side.