1f4a2713aSLionel Sambuc // RUN: %clang_cc1 -verify %s 2f4a2713aSLionel Sambuc 3f4a2713aSLionel Sambuc template<typename T> struct S { 4f4a2713aSLionel Sambuc static int a, b; 5f4a2713aSLionel Sambuc }; 6f4a2713aSLionel Sambuc 7f4a2713aSLionel Sambuc template<typename T> int S<T>::a, S<T>::b; // expected-error {{can only declare a single entity}} 8f4a2713aSLionel Sambuc 9f4a2713aSLionel Sambuc template<typename T> struct A { static A a; } A<T>::a; // expected-error {{expected ';' after struct}} \ 10f4a2713aSLionel Sambuc expected-error {{use of undeclared identifier 'T'}} \ 11*0a6a1f1dSLionel Sambuc expected-error {{no member named 'a'}} \ 12*0a6a1f1dSLionel Sambuc expected-warning {{extra qualification}} 13f4a2713aSLionel Sambuc 14f4a2713aSLionel Sambuc template<typename T> struct B { } f(); // expected-error {{expected ';' after struct}} \ 15f4a2713aSLionel Sambuc expected-error {{requires a type specifier}} 16f4a2713aSLionel Sambuc 17f4a2713aSLionel Sambuc template<typename T> struct C { } // expected-error {{expected ';' after struct}} 18f4a2713aSLionel Sambuc 19f4a2713aSLionel Sambuc A<int> c; 20