test-suite/bugs/bug_18281.v
raw| 1 | Require Import Ltac2.Ltac2. |
| 2 | |
| 3 | #[projections(primitive)] |
| 4 | Record r (n : nat) := { w : Prop -> Prop -> Prop }. |
| 5 | |
| 6 | Class C (P : Prop) := {}. |
| 7 | |
| 8 | Goal forall (v : r 0) (Q P : Prop), C (v.(w _) P Q). |
| 9 | Proof. |
| 10 | intros. |
| 11 | |
| 12 | #[local] Opaque w. |
| 13 | |
| 14 | lazy_match! goal with |
| 15 | | [ |- ?g ] => |
| 16 | let t := constr:(w 0) in |
| 17 | let t := constr:(C ($t v P Q)) in |
| 18 | Unification.unify (TransparentState.current ()) g t |
| 19 | end. |
| 20 | Abort. |