Erkki Luuk
2018-09-18 19:02:22 UTC
Hi
Can someone please explain this:
Require Import Ensembles.
Variable (n:nat) (r:Set).
Parameter natt:> nat -> Type.
Notation "{ x , y }" := ltac:(tryif first [refine (In Type (Couple Type x
y) _)
| exact (In Type (Couple Type x y) y)]
then idtac "ok" else idtac "{..,..} fail"; fail) (at level 9).
Notation "' x" := ltac:(first [refine (Couple_l Type (natt x) r)
| refine (Couple_r Type n x)]) (at level 9).
Check 'n: {n,r}. (*ok. Error: Tactic failure*)
It's strange enough to get "ok. Error: Tactic failure" here, *but* if I
comment "idtac "{..,..} fail";" out, I get "ok" and everything works.
Tested on 8.8.1
Cheers
Erkki
Can someone please explain this:
Require Import Ensembles.
Variable (n:nat) (r:Set).
Parameter natt:> nat -> Type.
Notation "{ x , y }" := ltac:(tryif first [refine (In Type (Couple Type x
y) _)
| exact (In Type (Couple Type x y) y)]
then idtac "ok" else idtac "{..,..} fail"; fail) (at level 9).
Notation "' x" := ltac:(first [refine (Couple_l Type (natt x) r)
| refine (Couple_r Type n x)]) (at level 9).
Check 'n: {n,r}. (*ok. Error: Tactic failure*)
It's strange enough to get "ok. Error: Tactic failure" here, *but* if I
comment "idtac "{..,..} fail";" out, I get "ok" and everything works.
Tested on 8.8.1
Cheers
Erkki