r191444 - Add macro test from N3781.
Richard Smith
richard-llvm at metafoo.co.uk
Thu Sep 26 11:15:22 PDT 2013
Author: rsmith
Date: Thu Sep 26 13:15:22 2013
New Revision: 191444
URL: http://llvm.org/viewvc/llvm-project?rev=191444&view=rev
Log:
Add macro test from N3781.
Modified:
cfe/trunk/test/Lexer/cxx1y_digit_separators.cpp
Modified: cfe/trunk/test/Lexer/cxx1y_digit_separators.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Lexer/cxx1y_digit_separators.cpp?rev=191444&r1=191443&r2=191444&view=diff
==============================================================================
--- cfe/trunk/test/Lexer/cxx1y_digit_separators.cpp (original)
+++ cfe/trunk/test/Lexer/cxx1y_digit_separators.cpp Thu Sep 26 13:15:22 2013
@@ -36,3 +36,8 @@ namespace floating {
#line 123'456
static_assert(__LINE__ == 123456, "");
+
+// x has value 0 in C++11 and 34 in C++1y.
+#define M(x, ...) __VA_ARGS__
+constexpr int x = { M(1'2,3'4) };
+static_assert(x == 34, "");
More information about the cfe-commits
mailing list