summaryrefslogtreecommitdiff
path: root/test/Preprocessor/print_line_track.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/Preprocessor/print_line_track.c')
-rw-r--r--test/Preprocessor/print_line_track.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/Preprocessor/print_line_track.c b/test/Preprocessor/print_line_track.c
new file mode 100644
index 0000000000..4fbef7407c
--- /dev/null
+++ b/test/Preprocessor/print_line_track.c
@@ -0,0 +1,15 @@
+/* RUN: clang -E %s | grep 'a 3'
+ * RUN: clang -E %s | grep 'b 14'
+ * RUN: clang -E -P %s | grep 'a 3'
+ * RUN: clang -E -P %s | grep 'b 14'
+ * PR1848
+*/
+
+#define t(x) x
+
+t(a
+3)
+
+t(b
+__LINE__)
+