Fix all Lean build warnings
- Update deprecated lemmas (ite_eq_left/right, ENat casts, List.Sublist, ...) - Replace push_neg with push Not and resolve unused-variable warnings - Convert flexible simp/simp_all calls to explicit simp only lists - Remove unscoped maxHeartbeats options, open scoped Classical, and unused tactics - Add missing module docstrings and clean up style linter hits - Wrap over-long lines and flatten the deeply nested minimal_conflictRangeClosedForm_total proof `lake build` now completes with zero warnings.
This commit is contained in:
1 parent
a54a5f82f8
commit
af318a7d32
51 files changed
+2542
-1357
No files matched your search
@@ -153,7 +153,8 @@ theorem crossed_rev_b_le_capBL {db : DB} {r : RangeRead} {res : Result}
|
||||
rw [← hik, hltake]
|
||||
exact lt_of_lt_of_le hklt hhead_le_L
|
||||
have hbetween : between db B (((L : Key)) : WithTop Key) =
|
||||
lB.filter (fun k : Key => decide (((k : Key) : WithTop Key) < (((L : Key)) : WithTop Key))) := by
|
||||
lB.filter (fun k : Key => decide (((k : Key) : WithTop Key) < (((L : Key)) : WithTop Key)))
|
||||
:= by
|
||||
rw [between_eq_filter_above, ← hlB]
|
||||
have hfilter_len : b ≤ (lB.filter (fun k : Key =>
|
||||
decide (((k : Key) : WithTop Key) < (((L : Key)) : WithTop Key)))).length := by
|
||||
@@ -493,7 +494,7 @@ theorem crossed_residual_above_end_lt_of_agree {db db' : DB} {r : RangeRead} {re
|
||||
calc ((above db' E).length : ℕ∞) ≤ intervalCard E ((L : Key) : WithTop Key) + (t : ℕ∞) :=
|
||||
hsumcast
|
||||
_ < ((e - t : ℕ) : ℕ∞) + (t : ℕ∞) :=
|
||||
WithTop.add_lt_add_right (z := (t : ℕ∞)) (ENat.coe_ne_top t) hnot'
|
||||
WithTop.add_lt_add_right (z := (t : ℕ∞)) (ENat.natCast_ne_top t) hnot'
|
||||
_ = (e : ℕ∞) := by rw [← Nat.cast_add]; congr 1; omega
|
||||
have := ENat.natCast_lt_natCast.mp hlt
|
||||
simpa [E, e] using this
|
||||
@@ -682,7 +683,7 @@ theorem crossed_residual_necessary_below_last_not_cond {r : RangeRead} {res : Re
|
||||
List.drop_eq_nil_of_le (le_of_eq hPlen), List.nil_append, hR, List.reverse_reverse]
|
||||
have hcompFull : RangeRead.Compatible dbfull r res := by
|
||||
refine ⟨hcomp₀.1, Or.inl ⟨hmore, ?_, hne⟩⟩
|
||||
simpa [hckFull] using List.prefix_refl res.keys
|
||||
simp [hckFull]
|
||||
refine necessary_of_toggle ⟨dbfull, hcompFull, ?_⟩
|
||||
have hkFull : k ∈ dbfull.keys := by
|
||||
rw [hfullKeys]
|
||||
@@ -743,7 +744,7 @@ theorem orderedInsert_eq_append_of_forall_lt {l : List Key} {k : Key}
|
||||
| cons a t ih =>
|
||||
rw [List.orderedInsert_cons]
|
||||
have hat : a < k := h a (by simp)
|
||||
rw [if_neg (not_le.mpr hat), ih (fun x hx => h x (by simp [hx]))]
|
||||
rw [ite_eq_right (not_le.mpr hat), ih (fun x hx => h x (by simp [hx]))]
|
||||
rfl
|
||||
|
||||
/-- Under the failure of the capacity condition, every key above the reported head is
|
||||
|
||||
Reference in new issue
Block a user