. next l_ne_i =>
  rw [Array.get_modify_unchanged l_in_bounds i_in_bounds _ l_ne_i]
  exact h
case neg
n : Nat
assignments : Array Assignment
assignments_size : assignments.size = n
units : Array (Literal (PosFin n))
foundContradiction : Bool
l : Literal (PosFin n)
insertUnit_res : Array (Literal (PosFin n)) × Array Assignment × Bool :=
  insertUnit (units, assignments, foundContradiction) l
h✝¹ : foundContradiction = true → ∃ i, assignments[i.val] = both
l_in_bounds : l.fst.val < assignments.size
hl : ¬hasAssignment l.snd assignments[l.fst.val]! = true
foundContradiction_eq_true : foundContradiction = true
i : PosFin n
h : assignments[i.val] = both
i_in_bounds : i.val < assignments.size
h✝ : ¬l.fst.val = i.val
⊢ (assignments.modify l.fst.val (addAssignment l.snd))[i.val] = both
no goals