Fix a bug where we would incorrectly emit a "cannot paste" error 
message when handling the GNU ", ## __VA_ARGS__" extension.  While
I'm at it, flag uses of this as extensions.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@46503 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/Preprocessor/macro_paste_commaext.c b/test/Preprocessor/macro_paste_commaext.c
new file mode 100644
index 0000000..0fcd90d
--- /dev/null
+++ b/test/Preprocessor/macro_paste_commaext.c
@@ -0,0 +1,13 @@
+// RUN: clang %s -E | grep 'V);' &&
+// RUN: clang %s -E | grep 'W, 1, 2);'
+// RUN: clang %s -E | grep 'X, 1, 2);'
+// RUN: clang %s -E | grep 'Y, );'
+// RUN: clang %s -E | grep 'Z, );'
+
+#define debug(format, ...) format, ## __VA_ARGS__)
+debug(V);
+debug(W, 1, 2);
+debug(X, 1, 2 );
+debug(Y, );
+debug(Z,);
+