aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--validation/empty-assign.c14
-rw-r--r--validation/empty-initializer.c10
2 files changed, 24 insertions, 0 deletions
diff --git a/validation/empty-assign.c b/validation/empty-assign.c
new file mode 100644
index 00000000..48ac626d
--- /dev/null
+++ b/validation/empty-assign.c
@@ -0,0 +1,14 @@
+static int foo(int a)
+{
+ a = ; // KO
+ return a;
+}
+
+/*
+ * check-name: empty-assign
+ * check-known-to-fail
+ *
+ * check-error-start
+empty-assign.c:3:11: error: expression expected before ';'
+ * check-error-end
+ */
diff --git a/validation/empty-initializer.c b/validation/empty-initializer.c
new file mode 100644
index 00000000..0ca763f6
--- /dev/null
+++ b/validation/empty-initializer.c
@@ -0,0 +1,10 @@
+static int i = ; // KO
+
+/*
+ * check-name: empty-initializer
+ * check-known-to-fail
+ *
+ * check-error-start
+empty-initializer.c:1:16: error: expression expected before ';'
+ * check-error-end
+ */