summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/cpp/multiline-2.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gcc.dg/cpp/multiline-2.c')
-rw-r--r--gcc/testsuite/gcc.dg/cpp/multiline-2.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/cpp/multiline-2.c b/gcc/testsuite/gcc.dg/cpp/multiline-2.c
new file mode 100644
index 00000000000..6a674b4dcd1
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/cpp/multiline-2.c
@@ -0,0 +1,14 @@
+/* Copyright (C) 2000, 2003 Free Software Foundation, Inc. */
+
+/* { dg-do compile } */
+
+/* Test that multi-line tokens are rejected by the compiler. Source:
+ Neil Booth. */
+
+const char *p = "line 1
+"
+""; /* The compiler front end sees this. */
+
+/* { dg-error "missing term" "multiline strings" { target *-*-* } 8 } */
+/* { dg-error "missing term" "multiline strings" { target *-*-* } 9 } */
+