Commit f889978a authored by Adam Chlipala's avatar Adam Chlipala

crush' pursues trivial inversions

parent 2cadc205
...@@ -42,6 +42,9 @@ Ltac all f ls := ...@@ -42,6 +42,9 @@ Ltac all f ls :=
end. end.
Ltac simplHyp invOne := Ltac simplHyp invOne :=
let invert H F :=
inList F invOne; (inversion H; fail)
|| (inversion H; [idtac]; clear H; try subst) in
match goal with match goal with
| [ H : ex _ |- _ ] => destruct H | [ H : ex _ |- _ ] => destruct H
...@@ -54,11 +57,11 @@ Ltac simplHyp invOne := ...@@ -54,11 +57,11 @@ Ltac simplHyp invOne :=
| [ |- _ = _ -> _ = _ -> _ ] => try clear H; intros; try subst | [ |- _ = _ -> _ = _ -> _ ] => try clear H; intros; try subst
end end
| [ H : ?F _ |- _ ] => inList F invOne; inversion H; [idtac]; clear H; try subst | [ H : ?F _ |- _ ] => invert H F
| [ H : ?F _ _ |- _ ] => inList F invOne; inversion H; [idtac]; clear H; try subst | [ H : ?F _ _ |- _ ] => invert H F
| [ H : ?F _ _ _ |- _ ] => inList F invOne; inversion H; [idtac]; clear H; try subst | [ H : ?F _ _ _ |- _ ] => invert H F
| [ H : ?F _ _ _ _ |- _ ] => inList F invOne; inversion H; [idtac]; clear H; try subst | [ H : ?F _ _ _ _ |- _ ] => invert H F
| [ H : ?F _ _ _ _ _ |- _ ] => inList F invOne; inversion H; [idtac]; clear H; try subst | [ H : ?F _ _ _ _ _ |- _ ] => invert H F
end. end.
Ltac rewriteHyp := Ltac rewriteHyp :=
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment