Debian Codegraph @

test-suite/bugs/bug_6617.v

raw
1 Definition MR {T M : Type} :=
2 fun (R : M -> M -> Prop) (m : T -> M) (x y : T) => R (m x) (m y).
3
4 Set Primitive Projections.
5
6 Record sigma {A : Type} {B : A -> Type} : Type := sigmaI
7 { pr1 : A; pr2 : B pr1 }.
8
9 Axiom F : forall {A : Type} {R : A -> A -> Prop},
10 (forall x, (forall y, R y x -> unit) -> unit) -> forall (x : A), unit.
11
12 Definition foo (A : Type) (l : list A) :=
13 let y := {| pr1 := A; pr2 := l |} in
14 let bar := MR lt (fun p : sigma =>
15 (fix Ffix (x : list (pr1 p)) : nat :=
16 match x with
17 | nil => 0
18 | cons _ x1 => S (Ffix x1)
19 end) (pr2 p)) in
20 fun (_ : bar y y) =>
21 F (fun (r : sigma)
22 (X : forall q : sigma, bar q r -> unit) => tt).
23
24 Definition fooT (A : Type) (l : list A) : Type :=
25 ltac:(let ty := type of (foo A l) in exact ty).
26 Parameter P : forall A l, fooT A l -> Prop.
27
28 Goal forall A l, P A l (foo A l).
29 Proof.
30 intros; unfold foo.
31 Fail match goal with
32 | [ |- context [False]] => idtac
33 end.
34 Admitted.