Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion theories/Arith/PeanoNat.v
Original file line number Diff line number Diff line change
Expand Up @@ -1253,7 +1253,7 @@ Qed.

Lemma OddT_S_EvenT n : OddT (S n) -> EvenT n.
Proof.
intros [k HO]; rewrite add_1_r in HO; injection HO; intros ->.
intros [k HO]; rewrite add_1_r in HO; injection HO as ->.
exists k; reflexivity.
Qed.

Expand Down
20 changes: 5 additions & 15 deletions theories/Lists/List.v
Original file line number Diff line number Diff line change
Expand Up @@ -2345,7 +2345,7 @@ Section Cutting.
Proof.
revert l x; induction n as [|n IH]; intros [|y l] x.
- discriminate.
- injection 1. intros ->. reflexivity.
- injection 1 as ->. reflexivity.
- discriminate.
- simpl. intros H. f_equal. apply IH. exact H.
Qed.
Expand Down Expand Up @@ -2955,19 +2955,9 @@ Section Compare.
intros Heq1 Heq2 Hne1 Hne2.
revert prefix2 xs1 xs2 ys1 ys2 Heq1 Heq2.
induction prefix1 as [|z prefix1 IH]; intros prefix2 xs1 xs2 ys1 ys2.
- destruct prefix2; [reflexivity|]. simpl. intros H1 H2.
injection H1; clear H1; intros ??; subst.
injection H2; clear H2; intros ??; subst.
exfalso. apply Hne1. reflexivity.
- destruct prefix2.
+ simpl. intros H1 H2.
injection H1; clear H1; intros ??; subst.
injection H2; clear H2; intros ??; subst.
exfalso. apply Hne2. reflexivity.
+ simpl. intros H1 H2.
injection H1; clear H1; intros ??; subst.
injection H2; clear H2; intros ?; subst.
intros. f_equal. eapply IH; eassumption.
- destruct prefix2; simpl; congruence.
- destruct prefix2; [simpl; congruence|].
injection 1 as; injection 1 as; subst; erewrite IH; eauto.
Qed.

#[local] Ltac list_auto :=
Expand All @@ -2981,7 +2971,7 @@ Section Compare.
| H : ?xs ++ _ = ?xs ++ _ |- _ =>
apply app_inv_head in H
| H : _ :: _ = _ :: _ |- _ =>
injection H; intros; clear H; subst
injection H as; subst
| H : [] = _ :: _ |- _ =>
inversion H
| H : cmp ?x ?x = Lt |- _ =>
Expand Down
Loading