Home | History | Annotate | Download | only in SemaCXX

Lines Matching full:template

7   template<typename T> struct initializer_list {
16 template<typename ...T> // expected-warning {{variadic templates are incompatible with C++98}}
19 template<template<typename> class ...T> // expected-warning {{variadic templates are incompatible with C++98}}
22 template<int ...I> // expected-warning {{variadic templates are incompatible with C++98}}
42 template<typename T> struct S {};
134 template<typename T> using AliasTemplate = T; // expected-warning {{alias declarations are incompatible with C++98}}
170 template<int n = 0> void DefaultFuncTemplateArg(); // expected-warning {{default template arguments for a function template are incompatible with C++98}}
172 template<typename T> int TemplateFn(T) { return 0; }
175 TemplateFn(S()); // expected-warning {{local type 'S' as template argument is incompatible with C++98}}
178 int UnnamedTemplateArg = TemplateFn(obj_of_unnamed_type); // expected-warning {{unnamed type as template argument is incompatible with C++98}}
182 template<int*p> struct S {};
183 S<(&n)> s; // expected-warning {{redundant parentheses surrounding address non-type template argument are incompatible with C++98}}
184 S<(((&n)))> t; // expected-warning {{redundant parentheses surrounding address non-type template argument are incompatible with C++98}}
188 template<typename T> struct S {}; // expected-note {{here}}
190 template<> struct TemplateSpecOutOfScopeNs::S<char> {}; // expected-warning {{class template specialization of 'S' outside namespace 'TemplateSpecOutOfScopeNs' is incompatible with C++98}}
193 template<typename T> struct Inner {};
195 typename ::Typename TypenameOutsideTemplate(); // expected-warning {{use of 'typename' outside of a template is incompatible with C++98}}
196 Typename::template Inner<int> TemplateOutsideTemplate(); // expected-warning {{use of 'template' keyword outside of a template is incompatible with C++98}}
225 template<typename T> typename T::ImPrivate SFINAEAccessControl(T t) { // expected-warning {{substitution failure due to access control is incompatible with C++98}}
229 int CheckSFINAEAccessControl = SFINAEAccessControl(PrivateMember()); // expected-note {{while substituting deduced template arguments into function template 'SFINAEAccessControl' [with T = PrivateMember]}}
261 template<typename T> void EnumNNSFn() {
264 template void EnumNNSFn<Enum>(); // expected-note {{in instantiation}}
300 template<typename T, T v> struct S {};
303 S<const int&, k> s1; // expected-warning {{non-type template argument referring to object 'k' with internal linkage is incompatible with C++98}}
304 S<void(&)(), f> s2; // expected-warning {{non-type template argument referring to function 'f' with internal linkage is incompatible with C++98}}
309 template<int*> struct X {};
310 template<int A::*> struct Y {};
311 X<(int*)0> x; // expected-warning {{use of null pointer as non-type template argument is incompatible with C++98}}
312 template argument is incompatible with C++98}}
353 template<typename T> T var = T(10);
361 // diagnosed the primary template.
362 template<typename T> T* var<T*> = new T();
363 template<> int var<int> = 10;
364 template int var<int>;
368 template<typename T> static T var = T(10);
375 template<typename T> static T* var<T*> = new T();
378 struct B { template<typename T> static T v; };
385 template<typename T> T B::v = T();
392 template<typename T> T* B::v<T*> = new T();
393 template<> int B::v<int> = 10;
394 template int B::v<int>;