template class foo { public: foo() { } class Z { };}; template void dep7(foo *) { } // { dg-error "" }