// RUN: %clang_cc1 -fsyntax-only -verify %s template struct A; // expected-note 4{{template is declared here}} template struct B : A { }; // expected-error{{implicit instantiation of undefined template}} \ // expected-error{{implicit instantiation of undefined template 'A'}} template struct C : B { } ; // expected-note{{instantiation of template class}} template struct D : C { }; // expected-note{{instantiation of template class}} template struct E : D { }; // expected-note{{instantiation of template class}} template struct F : E { }; // expected-note{{instantiation of template class}} void f() { (void)sizeof(F); // expected-note{{instantiation of template class}} } typedef struct { } X; void g() { (void)sizeof(B); // expected-note{{in instantiation of template class 'B' requested here}} } template struct G : A, // expected-error{{implicit instantiation of undefined template 'A'}} A // expected-error{{implicit instantiation of undefined template 'A'}} { }; void h() { (void)sizeof(G); // expected-note{{in instantiation of template class 'G' requested here}} } namespace PR13365 { template class ResultTy { // expected-warning {{does not declare any constructor}} T t; // expected-note {{reference member 't' will never be initialized}} }; template typename ResultTy::error Deduce( void (T1::*member)(T2) ) {} // \ // expected-note {{instantiation of template class 'PR13365::ResultTy'}} \ // expected-note {{substitution failure [with T1 = PR13365::Cls, T2 = int &]}} struct Cls { void method(int&); }; void test() { Deduce(&Cls::method); // expected-error {{no matching function}} \ // expected-note {{substituting deduced template arguments into function template 'Deduce' [with T1 = PR13365::Cls, T2 = int &]}} } }