Debian Codegraph @

test-suite/success/transparent_abstract.v

raw
1 Class by_transparent_abstract {T} (x : T) := make_by_transparent_abstract : T.
2 #[export] Hint Extern 0 (@by_transparent_abstract ?T ?x) => change T; transparent_abstract exact_no_check x : typeclass_instances.
3
4 Goal True /\ True.
5 Proof.
6 split.
7 transparent_abstract exact I using foo.
8 let x := (eval hnf in foo) in constr_eq x I.
9 let x := constr:(ltac:(constructor) : True) in
10 let T := type of x in
11 let x := constr:(_ : by_transparent_abstract x) in
12 let x := (eval cbv delta [by_transparent_abstract] in (let y : T := x in y)) in
13 pose x as x'.
14 simpl in x'.
15 let v := eval cbv [x'] in x' in tryif constr_eq v I then fail 0 else idtac.
16 hnf in x'.
17 let v := eval cbv [x'] in x' in tryif constr_eq v I then idtac else fail 0.
18 exact x'.
19 Defined.
20 Check eq_refl : I = foo.
21 Eval compute in foo.