1// { dg-do compile } 2 3// by Paul Burchard <burchard@pobox.com>, Level Set Systems, Inc. 4// Copyright (C) 1999, 2002 Free Software Foundation 5 6template<class T> 7class X { 8 class Y : public T 9 { // { dg-error "base type .* fails to be" } 10 }; 11 Y y; // { dg-message "instantiated" } 12}; 13int main() { 14 X<int> x; // { dg-message "instantiated" } 15} 16 17