summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/glsl/glcpp/tests/115-line-continuations.c9
-rw-r--r--src/glsl/glcpp/tests/115-line-continuations.c.expected10
-rw-r--r--src/glsl/glcpp/tests/116-disable-line-continuations.c13
-rw-r--r--src/glsl/glcpp/tests/116-disable-line-continuations.c.expected14
4 files changed, 46 insertions, 0 deletions
diff --git a/src/glsl/glcpp/tests/115-line-continuations.c b/src/glsl/glcpp/tests/115-line-continuations.c
new file mode 100644
index 00000000000..105590d85ed
--- /dev/null
+++ b/src/glsl/glcpp/tests/115-line-continuations.c
@@ -0,0 +1,9 @@
+// This comment continues to the next line, hiding the define \
+#define CONTINUATION_UNSUPPORTED
+
+#ifdef CONTINUATION_UNSUPPORTED
+failure
+#else
+success
+#endif
+
diff --git a/src/glsl/glcpp/tests/115-line-continuations.c.expected b/src/glsl/glcpp/tests/115-line-continuations.c.expected
new file mode 100644
index 00000000000..f67ba1cf72e
--- /dev/null
+++ b/src/glsl/glcpp/tests/115-line-continuations.c.expected
@@ -0,0 +1,10 @@
+
+
+
+
+
+
+success
+
+
+
diff --git a/src/glsl/glcpp/tests/116-disable-line-continuations.c b/src/glsl/glcpp/tests/116-disable-line-continuations.c
new file mode 100644
index 00000000000..83d5ddf681b
--- /dev/null
+++ b/src/glsl/glcpp/tests/116-disable-line-continuations.c
@@ -0,0 +1,13 @@
+// glcpp-args: --disable-line-continuations
+
+// This comments ends with a backslash \\
+#define NO_CONTINUATION
+
+#ifdef NO_CONTINUATION
+success
+#else
+failure
+#endif
+
+
+
diff --git a/src/glsl/glcpp/tests/116-disable-line-continuations.c.expected b/src/glsl/glcpp/tests/116-disable-line-continuations.c.expected
new file mode 100644
index 00000000000..9b9a8c5b6b9
--- /dev/null
+++ b/src/glsl/glcpp/tests/116-disable-line-continuations.c.expected
@@ -0,0 +1,14 @@
+
+
+
+
+
+
+success
+
+
+
+
+
+
+