summaryrefslogtreecommitdiff
path: root/test/Preprocessor
diff options
context:
space:
mode:
authorEd Schouten <ed@FreeBSD.org>2009-06-22 08:08:35 +0000
committerEd Schouten <ed@FreeBSD.org>2009-06-22 08:08:35 +0000
commitb897c8660c4ff7037dde81b9645737bc1c992abe (patch)
treeb6403365e77095a79062d3379c9e6aea0df5f088 /test/Preprocessor
parent7ef7bab7e3d06f660b059b903c231f100bb13cc5 (diff)
Notes
Diffstat (limited to 'test/Preprocessor')
-rw-r--r--test/Preprocessor/_Pragma-dependency2.c5
-rw-r--r--test/Preprocessor/_Pragma-syshdr2.c5
-rw-r--r--test/Preprocessor/pragma_sysheader.c3
-rw-r--r--test/Preprocessor/pragma_sysheader.h4
-rw-r--r--test/Preprocessor/print_line_count.c4
5 files changed, 16 insertions, 5 deletions
diff --git a/test/Preprocessor/_Pragma-dependency2.c b/test/Preprocessor/_Pragma-dependency2.c
new file mode 100644
index 0000000000000..c21c7c85d4858
--- /dev/null
+++ b/test/Preprocessor/_Pragma-dependency2.c
@@ -0,0 +1,5 @@
+// RUN: clang-cc -E %s -verify
+
+#define DO_PRAGMA _Pragma
+DO_PRAGMA ("GCC dependency \"blahblabh\"") // expected-error {{file not found}}
+
diff --git a/test/Preprocessor/_Pragma-syshdr2.c b/test/Preprocessor/_Pragma-syshdr2.c
deleted file mode 100644
index de7f2d3dc3b15..0000000000000
--- a/test/Preprocessor/_Pragma-syshdr2.c
+++ /dev/null
@@ -1,5 +0,0 @@
-// RUN: clang-cc -E %s 2>&1 | grep 'file not found'
-
-#define DO_PRAGMA _Pragma
-DO_PRAGMA ("GCC dependency \"blahblabh\"")
-
diff --git a/test/Preprocessor/pragma_sysheader.c b/test/Preprocessor/pragma_sysheader.c
new file mode 100644
index 0000000000000..49082b8c09d16
--- /dev/null
+++ b/test/Preprocessor/pragma_sysheader.c
@@ -0,0 +1,3 @@
+// RUN: clang -verify -pedantic %s -fsyntax-only
+// rdar://6899937
+#include "pragma_sysheader.h"
diff --git a/test/Preprocessor/pragma_sysheader.h b/test/Preprocessor/pragma_sysheader.h
new file mode 100644
index 0000000000000..b79bde584a98b
--- /dev/null
+++ b/test/Preprocessor/pragma_sysheader.h
@@ -0,0 +1,4 @@
+#pragma GCC system_header
+typedef int x;
+typedef int x;
+
diff --git a/test/Preprocessor/print_line_count.c b/test/Preprocessor/print_line_count.c
new file mode 100644
index 0000000000000..2eb62df486880
--- /dev/null
+++ b/test/Preprocessor/print_line_count.c
@@ -0,0 +1,4 @@
+/* RUN: clang -E -C -P %s | wc -l | grep 4
+ PR2741
+ comment */
+y