From 7050ceaa09a29c3f50620a8d3f8439c3d69a10d0 Mon Sep 17 00:00:00 2001 From: Hugo Herbelin Date: Wed, 26 Dec 2018 23:46:19 +0100 Subject: Documenting syntax "injection ... as [= pat1 ... patn ]". To prevent confusion, forbidding a mix of the "injection term as pat1 ... patn" and of the "injection term as [= pat1 ... patn]" syntax: If a "[= ...]" occurs, this should be a singleton list of patterns. --- test-suite/output/injection.out | 4 ++++ test-suite/output/injection.v | 8 ++++++++ 2 files changed, 12 insertions(+) create mode 100644 test-suite/output/injection.out create mode 100644 test-suite/output/injection.v (limited to 'test-suite') diff --git a/test-suite/output/injection.out b/test-suite/output/injection.out new file mode 100644 index 0000000000..ff40a478f3 --- /dev/null +++ b/test-suite/output/injection.out @@ -0,0 +1,4 @@ +The command has indeed failed with message: +Unexpected pattern. +The command has indeed failed with message: +Unexpected injection pattern. diff --git a/test-suite/output/injection.v b/test-suite/output/injection.v new file mode 100644 index 0000000000..bfd5a67bf5 --- /dev/null +++ b/test-suite/output/injection.v @@ -0,0 +1,8 @@ +(* Test error messages *) + +Goal forall x, (x,0) = (0, S x) -> x = 0. +Fail intros x H; injection H as [= H'] H''. +Fail intros x H; injection H as H' [= H'']. +intros x H; injection H as [= H' H'']. +exact H'. +Qed. -- cgit v1.2.3