1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
// PR c++/50080 template <typename T> struct A { template <typename U> struct B {}; }; template <typename T> void test() { typename A<T>::template B<int> b; } int main() { typename A<double>::template B<int> b; // { dg-error "template|expected" "" { target { ! c++11 } } } }