1// Copyright (C) 2004 Free Software Foundation 2// Contributed by Kriang Lerdsuwanakij <lerdsuwa@users.sourceforge.net> 3// { dg-do compile } 4 5// Check the type of non-type parameter in template template parameter 6// only if it is dependent. 7 8template <template <int* p> class T> 9struct X {}; 10 11template <typename U, template <U* p> class T> 12struct Y { 13 X<T> x; 14}; 15 16template <int* p> struct Z {}; 17 18Y<int, Z> y1; 19Y<char, Z> y2; // { dg-error "mismatch|expected|invalid" } 20