From 54986ed77297f7fe53cdc0cca360c9a6ac206a1f Mon Sep 17 00:00:00 2001 From: Gaëtan Gilbert Date: Mon, 6 Jan 2020 10:33:09 +0100 Subject: Fix #11360: discharge of template inductive with param only use of var --- test-suite/bugs/closed/bug_11360.v | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 test-suite/bugs/closed/bug_11360.v (limited to 'test-suite/bugs') diff --git a/test-suite/bugs/closed/bug_11360.v b/test-suite/bugs/closed/bug_11360.v new file mode 100644 index 0000000000..d8bc4a9f02 --- /dev/null +++ b/test-suite/bugs/closed/bug_11360.v @@ -0,0 +1,6 @@ +Section S. + Variable (A:Type). + #[universes(template)] + Inductive bar (d:A) := . +End S. +Check bar nat 0. -- cgit v1.2.3 From 15ec807cd201b49ed339d665c34c955a36b29745 Mon Sep 17 00:00:00 2001 From: Maxime Dénès Date: Fri, 20 Dec 2019 13:40:02 +0100 Subject: Fix #11140: Bidirectionality hints perform (surprising?) simplification We typecheck arguments like previously, using bidirectionality hints, but ultimately replace them with user-provided arguments on which we replay coercion traces. This is a fix which should be easy to backport, but there are two directions of future work: - Coercion traces for `Program` coercions (in these cases, we currently use the inferred arguments) - Separate the Coercion API in two phases: inference and application of coercions. It will make the approach taken here cleaner, and probably make it easier to interleave typing steps with coercion inference. Co-Authored-By: Gaëtan Gilbert --- test-suite/bugs/bug_11140.v | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 test-suite/bugs/bug_11140.v (limited to 'test-suite/bugs') diff --git a/test-suite/bugs/bug_11140.v b/test-suite/bugs/bug_11140.v new file mode 100644 index 0000000000..ca806ea324 --- /dev/null +++ b/test-suite/bugs/bug_11140.v @@ -0,0 +1,11 @@ +Axiom T : nat -> Prop. +Axiom f : forall x, T x. +Arguments f & x. + +Lemma test : (f (1 + _) : T 2) = f 2. +match goal with +| |- (f (1 + 1) = f 2) => idtac +| |- (f 2 = f 2) => fail (* Issue 11140 *) +| |- _ => fail +end. +Abort. -- cgit v1.2.3