Debian Codegraph @

gcc/testsuite/g++.dg/lookup/hidden-class17.C

raw
1 // Origin PR c++/51641
2 // { dg-do compile }
3
4 struct A {
5 struct B { typedef int X; };
6 };
7
8 template<class B> struct C : A {
9 B::X q; // Ok: A::B.
10 struct U { typedef int X; };
11 template<class U>
12 struct D;
13 };
14
15 template<class B>
16 template<class U>
17 struct C<B>::D {
18 typename U::X r; // { dg-error "" }
19 };
20
21 C<int>::D<double> y;
22