Skip to content

Commit b7e8864

Browse files
committed
Improve proof of equiv_of_length_two
1 parent 3d8254f commit b7e8864

1 file changed

Lines changed: 4 additions & 16 deletions

File tree

TraceTheory/TraceTheory/Trace.lean

Lines changed: 4 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -175,23 +175,11 @@ lemma equiv_of_length_two {a b : α} {w : List α} (h : TraceEquiv I [a, b] w) :
175175
rw [hw] at h ⊢
176176
by_cases heq : a = b
177177
· subst heq
178-
have hc : c = a := by
179-
have h' := (equiv_implies_alph_eq I c h.symm).mp
180-
simp at h'
181-
exact h'
182-
have hd : d = a := by
183-
have h' := (equiv_implies_alph_eq I d h.symm).mp
184-
simp at h'
185-
exact h'
178+
have hc : c = a := by simpa using (equiv_implies_alph_eq I c h.symm).mp
179+
have hd : d = a := by simpa using (equiv_implies_alph_eq I d h.symm).mp
186180
simp [hc, hd]
187-
· have ha : a = c ∨ a = d := by
188-
have h' := (equiv_implies_alph_eq I a h).mp
189-
simp at h'
190-
exact h'
191-
have hb : b = c ∨ b = d := by
192-
have h' := (equiv_implies_alph_eq I b h).mp
193-
simp at h'
194-
exact h'
181+
· have ha : a = c ∨ a = d := by simpa using (equiv_implies_alph_eq I a h).mp
182+
have hb : b = c ∨ b = d := by simpa using (equiv_implies_alph_eq I b h).mp
195183
rcases ha with hac | had <;> rcases hb with hbc | hbd
196184
· rw [← hbc] at hac
197185
contradiction

0 commit comments

Comments
 (0)