summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFrançois Pottier <francois.pottier@inria.fr>2018-09-05 15:31:14 +0200
committerFrançois Pottier <francois.pottier@inria.fr>2018-09-05 15:47:37 +0200
commita1d90ac0c4b67bc322b2e05214a06e1c1957639f (patch)
tree9a55e54c344cb2fe47b63ac4ae41d379b2dc2498
parent298c1dc5614f176d202a095a7430b52acafd55ae (diff)
downloadocaml-a1d90ac0c4b67bc322b2e05214a06e1c1957639f.tar.gz
Add a regression test for MPR7847.
-rw-r--r--testsuite/tests/parse-errors/ocamltests1
-rw-r--r--testsuite/tests/parse-errors/pr7847.compilers.reference2
-rw-r--r--testsuite/tests/parse-errors/pr7847.ml10
3 files changed, 13 insertions, 0 deletions
diff --git a/testsuite/tests/parse-errors/ocamltests b/testsuite/tests/parse-errors/ocamltests
index 7373985db8..314733eee7 100644
--- a/testsuite/tests/parse-errors/ocamltests
+++ b/testsuite/tests/parse-errors/ocamltests
@@ -1,5 +1,6 @@
escape_error.ml
expecting.ml
+pr7847.ml
unclosed_class_signature.mli
unclosed_class_simpl_expr1.ml
unclosed_class_simpl_expr2.ml
diff --git a/testsuite/tests/parse-errors/pr7847.compilers.reference b/testsuite/tests/parse-errors/pr7847.compilers.reference
new file mode 100644
index 0000000000..1bc0fef14a
--- /dev/null
+++ b/testsuite/tests/parse-errors/pr7847.compilers.reference
@@ -0,0 +1,2 @@
+File "pr7847.ml", line 10, characters 30-31:
+Error: Syntax error
diff --git a/testsuite/tests/parse-errors/pr7847.ml b/testsuite/tests/parse-errors/pr7847.ml
new file mode 100644
index 0000000000..8018109b1e
--- /dev/null
+++ b/testsuite/tests/parse-errors/pr7847.ml
@@ -0,0 +1,10 @@
+(* TEST
+* setup-ocamlc.byte-build-env
+** ocamlc.byte
+ocamlc_byte_exit_status = "2"
+*** check-ocamlc.byte-output
+*)
+
+(* https://caml.inria.fr/mantis/view.php?id=7847
+ The backquote causes a syntax error; this file should be rejected. *)
+external x : unit -> (int,int)`A.t = "x"