diff options
author | Richard Smith <richard-llvm@metafoo.co.uk> | 2017-08-16 00:06:07 +0000 |
---|---|---|
committer | Richard Smith <richard-llvm@metafoo.co.uk> | 2017-08-16 00:06:07 +0000 |
commit | 48d699f0c1bea33e68829c2a8aa254ff8b5ac6ff (patch) | |
tree | 2393e688d79a512240d633f75359bc150af76b7b /test/Lexer | |
parent | fea7a1940941fce10a7e30508fced96542d23c46 (diff) | |
download | clang-48d699f0c1bea33e68829c2a8aa254ff8b5ac6ff.tar.gz |
Add missing test for warning added in r310803.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@310978 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Lexer')
-rw-r--r-- | test/Lexer/cxx2a_keyword_as_cxx17.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/Lexer/cxx2a_keyword_as_cxx17.cpp b/test/Lexer/cxx2a_keyword_as_cxx17.cpp new file mode 100644 index 0000000000..c6a821be0e --- /dev/null +++ b/test/Lexer/cxx2a_keyword_as_cxx17.cpp @@ -0,0 +1,9 @@ +// RUN: %clang_cc1 %s -verify -fsyntax-only -Wc++2a-compat -std=c++17 + +#define concept constexpr bool +template<typename T> +concept x = 0; +#undef concept + +int concept = 0; // expected-warning {{'concept' is a keyword in C++2a}} +int requires = 0; // expected-warning {{'requires' is a keyword in C++2a}} |