1// { dg-do assemble } 2// Origin: Mark Mitchell <mark@codesourcery.com> 3 4template <class T> 5struct S { 6 typedef typename T::Y<T>::Z X; // { dg-error "non-template" "non-template" } No Y in A 7// { dg-message "note" "note" { target *-*-* } 6 } 8// { dg-error "does not declare" "not declare" { target *-*-* } 6 } 9 X x; // { dg-error "does not name a type" } No Y in A 10}; 11 12struct A { 13 struct Y { 14 typedef A Z; 15 }; 16}; 17 18template struct S<A>; 19