aboutsummaryrefslogtreecommitdiff
path: root/test-suite
diff options
context:
space:
mode:
authorPierre-Marie Pédrot2020-08-24 12:36:07 +0200
committerPierre-Marie Pédrot2020-08-24 12:36:07 +0200
commit80aca0417e2ed8530b10185fda1cf8a9673e196d (patch)
treed6b831fa385439345fa5e1a895d9a79de27c6e56 /test-suite
parent98734a2d5ad419b99777dfd546ef482b5986cfda (diff)
parent68a18c80332bace9064e202d13f01c880cc114ec (diff)
Merge PR #12816: Fixes #12787: anomaly of tactic injection in the presence of artificial dependencies disappearing by reduction
Reviewed-by: ppedrot
Diffstat (limited to 'test-suite')
-rw-r--r--test-suite/bugs/closed/bug_12787.v26
1 files changed, 26 insertions, 0 deletions
diff --git a/test-suite/bugs/closed/bug_12787.v b/test-suite/bugs/closed/bug_12787.v
new file mode 100644
index 0000000000..2566e1f261
--- /dev/null
+++ b/test-suite/bugs/closed/bug_12787.v
@@ -0,0 +1,26 @@
+Inductive sigT3 {A: Type} {P: A -> Type} (Q: forall a: A, P a -> Type) :=
+ existT3: forall a: A, forall b: P a, Q a b -> sigT3 Q
+.
+
+Definition projT3_1 {A: Type} {P: A -> Type} {Q: forall a: A, P a -> Type} (a: sigT3 Q) :=
+ let 'existT3 _ x0 _ _ := a in x0.
+
+Definition projT3_2 {A: Type} {P: A -> Type} {Q: forall a: A, P a -> Type} (a: sigT3 Q) : P (projT3_1 a) :=
+ let 'existT3 _ x0 x1 _ := a in x1.
+
+
+
+Lemma projT3_3_eq' (A B: Type) (Q: B -> Type) (a b: sigT3 (fun (_: A) b => Q b)) (H: a = b) :
+ unit.
+Proof.
+ destruct a as [x0 x1 x2], b as [y0 y1 y2].
+ assert (H' := f_equal projT3_1 H).
+ cbn in H'.
+ subst x0.
+ assert (H' := f_equal (projT3_2 (P := fun _ => B)) H).
+ cbn in H'.
+ subst x1.
+
+ injection H as H'.
+ exact tt.
+Qed.