| 1 |
// RUN: %clang_cc1 -std=c++1z -verify %s |
| 2 |
|
| 3 |
[[disable_tail_calls, noduplicate]] void f() {} // expected-warning {{unknown attribute 'disable_tail_calls'}} expected-warning {{unknown attribute 'noduplicate'}} |
| 4 |
|
| 5 |
[[using clang: disable_tail_calls, noduplicate]] void g() {} // ok |
| 6 |
|
| 7 |
[[using]] extern int n; // expected-error {{expected identifier}} |
| 8 |
[[using foo |
| 9 |
] // expected-error {{expected ':'}} |
| 10 |
] extern int n; |
| 11 |
[[using 42:]] extern int n; // expected-error {{expected identifier}} |
| 12 |
[[using clang:]] extern int n; // ok |
| 13 |
[[using blah: clang::optnone]] extern int n; // expected-error {{attribute with scope specifier cannot follow}} expected-warning {{only applies to functions}} |
| 14 |
|
| 15 |
[[using clang: unknown_attr]] extern int n; // expected-warning {{unknown attribute}} |
| 16 |
[[using unknown_ns: something]] extern int n; // expected-warning {{unknown attribute}} |