lean4-htt/src/Init/Data/Array
Paul Reichert 0725349bbd
feat: high-level order typeclasses (#9729)
This PR introduces a canonical way to endow a type with an order
structure. The basic operations (`LE`, `LT`, `Min`, `Max`, and in later
PRs `BEq`, `Ord`, ...) and any higher-level property (a preorder, a
partial order, a linear order etc.) are then put in relation to `LE` as
necessary. The PR provides `IsLinearOrder` instances for many core types
and updates the signatures of some lemmas.

**BREAKING CHANGES:**

* The requirements of the `lt_of_le_of_lt`/`le_trans` lemmas for
`Vector`, `List` and `Array` are simplified. They now require an
`IsLinearOrder` instance. The new requirements are logically equivalent
to the old ones, but the `IsLinearOrder` instance is not automatically
inferred from the smaller typeclasses.
* Hypotheses of type `Std.Total (¬ · < · : α → α → Prop)` are replaced
with the equivalent class `Std.Asymm (· < · : α → α → Prop)`. Breakage
should be limited because there is now an instance that derives the
latter from the former.
* In `Init.Data.List.MinMax`, multiple theorem signatures are modified,
replacing explicit parameters for antisymmetry, totality, `min_ex_or`
etc. with corresponding instance parameters.
2025-08-11 14:55:17 +00:00
..
Lex feat: high-level order typeclasses (#9729) 2025-08-11 14:55:17 +00:00
QSort feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
Subarray feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
Attach.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
Basic.lean feat: default let rec and where decls to private under the module system (#9759) 2025-08-06 15:53:51 +00:00
BasicAux.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
BinSearch.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
Bootstrap.lean chore: remove >6 month old deprecations (#9640) 2025-08-05 02:29:15 +00:00
Count.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
DecidableEq.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
Erase.lean feat: pattern inference using symbol priorities in grind (#9182) 2025-07-03 16:47:38 -07:00
Extract.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
Find.lean fix: module system: remove WellFounded-specific hacks (#9143) 2025-07-02 11:58:50 +00:00
FinRange.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
GetLit.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
InsertIdx.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
InsertionSort.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
Lemmas.lean feat: default let rec and where decls to private under the module system (#9759) 2025-08-06 15:53:51 +00:00
Lex.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
MapIdx.lean chore: remove >6 month old deprecations (#9640) 2025-08-05 02:29:15 +00:00
Mem.lean chore: library style cleanup (#9654) 2025-07-31 21:28:59 +00:00
Monadic.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
OfFn.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
Perm.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
QSort.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
Range.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
Set.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
Subarray.lean chore: fix spelling errors (#9175) 2025-07-24 23:35:32 +00:00
TakeDrop.lean feat: make private the default in module (#9044) 2025-06-28 16:30:53 +00:00
Zip.lean feat: Add List.zipWithM and Array.zipWithM (#9528) 2025-07-28 08:39:52 +00:00