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
@@ -60,7 +60,7 @@ theorem clampLong_headD_eq {hne : res.keys ≠ []} :
|
||||
/-- Every reported key lies below `end_.key` in the crossed negative-begin complete
|
||||
long clamp cell. -/
|
||||
theorem clampLong_reported_lt_end (hread : Readable r res)
|
||||
(hrev : r.reverse = false) (hmore : res.more = false) (hend : r.end_.offset ≤ 0) :
|
||||
(_hrev : r.reverse = false) (hmore : res.more = false) (hend : r.end_.offset ≤ 0) :
|
||||
∀ k ∈ res.keys, ((k : Key) : WithTop Key) < r.end_.key := by
|
||||
obtain ⟨db, hcomp⟩ := hread
|
||||
have hres_eq : res.keys = RangeRead.completeKeys db r := by
|
||||
@@ -351,7 +351,8 @@ theorem exists_clampLong_db {r : RangeRead} {res : Result}
|
||||
omega
|
||||
have hdbk : db.keys = res.keys ++ L := by rw [hdb]
|
||||
have hRE : resolve db r.end_ = ((L.head hLne : Key) : WithTop Key) := by
|
||||
rw [resolve_eq_getElem hanchorE_nonneg (by rw [htoNatE, hdbk]; simp only [List.length_append]; omega)]
|
||||
rw [resolve_eq_getElem hanchorE_nonneg
|
||||
(by rw [htoNatE, hdbk]; simp only [List.length_append]; omega)]
|
||||
simp only [htoNatE, hdbk]
|
||||
rw [List.getElem_append_right (show res.keys.length ≤ res.keys.length by omega)]
|
||||
simp [List.head_eq_getElem]
|
||||
@@ -556,7 +557,8 @@ theorem exists_long_compat_db {r : RangeRead} {res : Result} {db₀ : DB}
|
||||
rw [List.filter_append, hBf, hGf, List.length_append]
|
||||
have hanchorE : r.end_.anchor db = ((H.length + res.keys.length : ℕ) : ℤ) := by
|
||||
unfold Selector.anchor
|
||||
have hc : db.keys.countP (fun k => decide (((k : Key) : WithTop Key) < r.end_.key)) = B.length := by
|
||||
have hc : db.keys.countP (fun k => decide (((k : Key) : WithTop Key) < r.end_.key)) = B.length
|
||||
:= by
|
||||
simpa [cnt] using hcntE
|
||||
rw [hc, hBlength]
|
||||
push_cast
|
||||
|
||||
Reference in new issue
Block a user