1 // RUN: %clang_cc1 -std=c++11 -verify=ext -fsyntax-only -Wfuture-attribute-extensions %s
2 // RUN: %clang_cc1 -std=c++11 -verify -fsyntax-only -Wno-future-attribute-extensions %s
3 // RUN: %clang_cc1 -std=c++11 -verify -fsyntax-only -Wno-c++14-attribute-extensions -Wno-c++17-attribute-extensions -Wno-c++20-attribute-extensions %s
5 // expected-no-diagnostics
7 [[deprecated
]] int func1(); // ext-warning {{use of the 'deprecated' attribute is a C++14 extension}}
8 [[deprecated("msg")]] int func2(); // ext-warning {{use of the 'deprecated' attribute is a C++14 extension}}
10 [[nodiscard
]] int func3(); // ext-warning {{use of the 'nodiscard' attribute is a C++17 extension}}
11 [[nodiscard("msg")]] int func4(); // ext-warning {{use of the 'nodiscard' attribute is a C++20 extension}}
14 if (true) [[likely
]]; // ext-warning {{use of the 'likely' attribute is a C++20 extension}}