#line is allowed to have macros that expand to nothing after them.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69401 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/Preprocessor/line-directive.c b/test/Preprocessor/line-directive.c
index 66efae9..1dd8b29 100644
--- a/test/Preprocessor/line-directive.c
+++ b/test/Preprocessor/line-directive.c
@@ -60,3 +60,11 @@
 
 typedef int w;  // expected-note {{previous definition is here}}
 typedef int w;  // expected-error {{redefinition of typedef 'w' is invalid in C}}
+
+
+// This should not produce an "extra tokens at end of #line directive" warning,
+// because #line is allowed to contain expanded tokens.
+#define EMPTY()
+#line 2 "foo.c" EMPTY( )
+#line 2 "foo.c" NONEMPTY( )  // expected-warning{{extra tokens at end of #line directive}}
+