aboutsummaryrefslogtreecommitdiff
path: root/test/Preprocessor/macro_paste_msextensions.c
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2010-07-17 16:24:30 +0000
committerChris Lattner <sabre@nondot.org>2010-07-17 16:24:30 +0000
commit920bf45bd739334c25633ec9a29d903cab50be23 (patch)
tree6501be75d23e735e448b33a90c5f60e413914dd0 /test/Preprocessor/macro_paste_msextensions.c
parent3e88dcf26e43db4b5e85b3ad681ebe53ee23d35f (diff)
Add another terrible VC++ compatibility hack: allow users to
allow invalid token pastes (when in -fms-extensions mode) with -Wno-invalid-token-paste git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108624 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Preprocessor/macro_paste_msextensions.c')
-rw-r--r--test/Preprocessor/macro_paste_msextensions.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/Preprocessor/macro_paste_msextensions.c b/test/Preprocessor/macro_paste_msextensions.c
index 71324064f7..c5b42130b8 100644
--- a/test/Preprocessor/macro_paste_msextensions.c
+++ b/test/Preprocessor/macro_paste_msextensions.c
@@ -1,4 +1,5 @@
// RUN: %clang_cc1 -P -E -fms-extensions %s | FileCheck -strict-whitespace %s
+
// This horrible stuff should preprocess into (other than whitespace):
// int foo;
// int bar;
@@ -24,3 +25,10 @@ nested(baz) rise of the dead tokens
// CHECK: int baz
// CHECK: ;
+
+// rdar://8197149 - VC++ allows invalid token pastes: (##baz
+#define foo(x) abc(x)
+#define bar(y) foo(##baz(y))
+bar(q)
+
+// CHECK: abc(baz(q))