aboutsummaryrefslogtreecommitdiff
path: root/test/Frontend/stdin2.c
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2010-08-06 12:06:13 +0000
committerDouglas Gregor <dgregor@apple.com>2010-08-06 12:06:13 +0000
commit91db30ad4a7bad37b57748c31f8b592b7bf7cbeb (patch)
tree157ac845f2d2cb0c9114d3bfed987615bdca5b2e /test/Frontend/stdin2.c
parented328c6129152f66771c3bed338a2e6e13e4e230 (diff)
Fix the #include search path when reading from stdin, from Jon Simons!
Fixes PR4897. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@110440 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Frontend/stdin2.c')
-rw-r--r--test/Frontend/stdin2.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/Frontend/stdin2.c b/test/Frontend/stdin2.c
new file mode 100644
index 0000000000..5a615e572c
--- /dev/null
+++ b/test/Frontend/stdin2.c
@@ -0,0 +1,11 @@
+// RUN: cd %S && %clang_cc1 -E - < stdin2.c
+
+/*
+ * Bug 4897; current working directory should be searched
+ * for #includes when input is stdin.
+ */
+
+#ifndef BUG_4897
+#define BUG_4897
+#include "stdin2.c"
+#endif