[AMDGPU] Update base addr of dyn alloca considering GrowingUp stack (#119822)
[llvm-project.git] / clang / test / CXX / over / over.oper / over.literal / p2.cpp
blobcf26806e9e7d757319d5618f7d16496fa14b68d7
1 // RUN: %clang_cc1 -std=c++11 %s -verify
3 void operator ""_a(const char *);
5 namespace N {
6 using ::operator ""_a;
8 void operator ""_b(const char *);
11 using N::operator ""_b;
13 class C {
14 void operator ""_c(const char *); // expected-error {{must be in a namespace or global scope}}
16 static void operator ""_c(unsigned long long); // expected-error {{must be in a namespace or global scope}}
18 friend void operator ""_d(const char *);
21 int operator ""_e; // expected-error {{cannot be the name of a variable}}
23 void f() {
24 int operator ""_f; // expected-error {{cannot be the name of a variable}}
27 extern "C++" {
28 void operator ""_g(const char *);
31 template<char...> void operator ""_h() {}
33 template<> void operator ""_h<'a', 'b', 'c'>() {}
35 template void operator ""_h<'a', 'b', 'c', 'd'>();
37 namespace rdar13605348 {
39 class C {
40 double operator""_x(long double value) { return double(value); } // expected-error{{literal operator 'operator""_x' must be in a namespace or global scope}}
41 double value() { return 3.2_x; } // expected-error{{no matching literal operator for call to}}