aboutsummaryrefslogtreecommitdiff
path: root/test/Preprocessor/import_self.c
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2007-11-15 19:07:47 +0000
committerChris Lattner <sabre@nondot.org>2007-11-15 19:07:47 +0000
commitb283298f03d2b512204d14ca687f9de263eeff0f (patch)
tree5b80740c4412252a27c6714c6499faca98f0c262 /test/Preprocessor/import_self.c
parent767dd4b8306c81ab16d9c428ed1d5d39678315bb (diff)
fix a bug Steve noticed, where a #import of the main file itself would fail.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44178 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Preprocessor/import_self.c')
-rw-r--r--test/Preprocessor/import_self.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/Preprocessor/import_self.c b/test/Preprocessor/import_self.c
new file mode 100644
index 0000000000..e8f6fa793d
--- /dev/null
+++ b/test/Preprocessor/import_self.c
@@ -0,0 +1,7 @@
+// RUN: clang -E -I. %s | grep BODY_OF_FILE | wc -l | grep 1
+
+// This #import should have no effect, as we're importing the current file.
+#import <import_self.c>
+
+BODY_OF_FILE
+