1 // { dg-do compile } 2 3 // Origin: Volker Reichelt <reichelt@gcc.gnu.org> 4 5 // PR c++/11076: ICE for invalid access declaration containing typename. 6 7 template<typename, typename T=void> struct A 8 { 9 typedef A<T,T> B; 10 }; 11 12 template <typename T> struct C 13 { 14 typedef typename A<T>::B X; 15 X::Y; // { dg-error "not a base type" } 16 // { dg-warning "deprecated" "" { target *-*-* } .-1 } 17 }; 18 19 C<void> c; 20