mirror of
https://github.com/achlipala/frap.git
synced 2024-11-10 00:07:51 +00:00
Simplify sets in hypotheses, too
This commit is contained in:
parent
89b1b74c7b
commit
c8322773a4
1 changed files with 8 additions and 0 deletions
8
Sets.v
8
Sets.v
|
@ -568,6 +568,10 @@ Ltac quote E env k :=
|
|||
Ltac sets_cbv := cbv beta iota zeta delta [interp_normal_form normalize_setexpr nth_default
|
||||
setmerge Elements Other nth_error map dedup member beq_nat orb
|
||||
andb included].
|
||||
|
||||
Ltac sets_cbv_in H := cbv beta iota zeta delta [interp_normal_form normalize_setexpr nth_default
|
||||
setmerge Elements Other nth_error map dedup member beq_nat orb
|
||||
andb included] in H.
|
||||
|
||||
Ltac normalize_set :=
|
||||
match goal with
|
||||
|
@ -575,6 +579,10 @@ Ltac normalize_set :=
|
|||
quote (@union A X Y) (@nil A) ltac:(fun e env =>
|
||||
change (@union A X Y) with (interp_setexpr env e));
|
||||
rewrite <- normalize_setexpr_ok; sets_cbv
|
||||
| [ H : context[@union ?A ?X ?Y] |- _ ] =>
|
||||
quote (@union A X Y) (@nil A) ltac:(fun e env =>
|
||||
change (@union A X Y) with (interp_setexpr env e) in H);
|
||||
rewrite <- normalize_setexpr_ok in H; sets_cbv_in H
|
||||
end.
|
||||
|
||||
Ltac compare_sets :=
|
||||
|
|
Loading…
Reference in a new issue