leanprover / lean4

Lean 4 programming language and theorem prover
https://lean-lang.org
Apache License 2.0
4.75k stars 427 forks source link

feat: Array.swap takes Nat arguments, with tactic provided proofs #6194

Closed kim-em closed 5 days ago

kim-em commented 5 days ago

This PR changes the signature of Array.swap, so it takes Nat arguments with tactic provided bounds checking. It also renames Array.swap! to Array.swapIfInBounds.

leanprover-community-bot commented 5 days ago

Mathlib CI status (docs):