1 // RUN: %clang_cc1 -std=c++11 %s -verify 2 3 using size_t = decltype(sizeof(int)); 4 template<char...> struct S {}; 5 6 template<char...> void operator "" _a(); 7 template<char... C> S<C...> operator "" _a(); 8 9 template<typename T> struct U { 10 friend int operator "" _a(const char *, size_t); 11 // FIXME: It's not entirely clear whether this is intended to be legal. 12 friend U operator "" _a(const T *, size_t); // expected-error {{parameter}} 13 }; 14 template<char...> struct V { 15 friend void operator "" _b(); // expected-error {{parameters}} 16 }; 17 18 template<char... C, int N = 0> void operator "" _b(); // expected-error {{template}} 19 template<char... C> void operator "" _b(int N = 0); // expected-error {{template}} 20 template<char, char...> void operator "" _b(); // expected-error {{template}} 21 template<typename T> T operator "" _b(const char *); // expected-error {{template}} 22 template<typename T> int operator "" _b(const T *, size_t); // expected-error {{template}} 23