[Bug c++/117993] [15 regression] this->x is being rejected in a nested template class with a base of class of the outer templated class since r15-2117
ppalka at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Dec 11 15:31:51 GMT 2024
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117993
--- Comment #7 from Patrick Palka <ppalka at gcc dot gnu.org> ---
(In reply to Patrick Palka from comment #6)
> (In reply to Andrew Pinski from comment #4)
> > (In reply to Andrew Pinski from comment #3)
> > > I suspect for some reason we think the current instantiation does not have a
> > > dependent base for some reason.
> >
> > That is any_dependent_bases_p is returning false for `struct B<T>::C<n>`
> > type.
> Indeed, so it seems any_dependent_bases_p should recursively consider
> indirect bases.
>
> Or for
>
> template<class T>
> struct B { template<class U> struct C; };
Whoops, this should be e.g.
struct B : T { template<class U> struct C; };
More information about the Gcc-bugs
mailing list