match hf with
| .nil => 
  rw[empty_heap_merge_left] at *
  rw[hrank_of_cons] at *
  unfold bne at *
  rw[Bool.not_eq_false', beq_iff_eq] at *
  simp at *
  contradiction
| .cons (t := t₂) (ts := ts₂) _ _ _ =>
  repeat rw[hrank_of_cons] at *
  unfold bne at *
  rw[Bool.not_eq_false', beq_iff_eq] at *
  simp at *
  have ht₁ : IsHeapForest' h₁.rank (t₂ :: ts₂) := by
    apply IsHeapForest'_of_IsHeapForest' <;> assumption
  have ht₂ : IsHeapForest' h₁.rank (t :: ts) := by
    rw[← heq] at *
    apply IsHeapForest'_of_IsHeapForest' <;> assumption
  have : t₂.rank + 1 ≤ hRank (mergeNodes le (t₂ :: ts₂) (t :: ts)) := by
    apply hRank_mergeNodes_cons ht₁ ht₂
    simp_all
  rename_i heq₂ _
  rw[heq₂]
  apply Nat.lt_of_succ_le this
α : Type u_1
le : α → α → Bool
rx : ℕ
xs : List (BinTree α)
ry : ℕ
ys : List (BinTree α)
h₁ : BinTree α
t₁ : List (BinTree α)
h₂ : BinTree α
t₂ : List (BinTree α)
not_le_le : ∀ (x y : α), le x y = false → le y x = true
h✝⁴ : h₂.rank ≤ h₁.rank
h✝³ : h₁.rank ≤ h₂.rank
h✝² : (h₁.rank + 1 != hRank t₁) = false
heq : h₁.rank = h₂.rank
a✝⁶ : IsBinTree h₁
a✝⁵ : rx < h₁.rank
hf : IsHeapForest' h₁.rank t₁
a✝⁴ : IsBinTree h₂
a✝³ : ry < h₂.rank
hf₂ : IsHeapForest' h₂.rank t₂
t : BinTree α
ts : List (BinTree α)
a✝² : h₂.rank < t.rank
a✝¹ : IsBinTree t
a✝ : IsHeapForest' t.rank ts
h✝¹ : (h₁.rank + 1 != hRank (t :: ts)) = false
ih : IsHeapForest' (min h₁.rank h₂.rank) (mergeNodes le t₁ (t :: ts))
h : ¬(t₁ = [] ∧ t :: ts = [])
h✝ : hRank t₁ ≤ hRank (t :: ts)
hle : hRank t₁ ≤ hRank (mergeNodes le t₁ (t :: ts))
⊢ h₁.rank + 1 < hRank (mergeNodes le t₁ (t :: ts))
no goals