https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104850
--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> --- Interesting if I put the definition of the class A::B at the end of the file, the code works .... I wonder if this is because of some ABI issue where A::A as a base class is created ....