Lean 4 fork for HoTT-compatible kernel extensions (Path types, transport, HITs). Maintained against upstream leanprover/lean4.
Find a file
Leonardo de Moura aa5b392e35
fix: canonicalization of non-standard OfNat.ofNat terms (#9481)
This PR fixes a kernel type mismatch that occurs when using `grind` on
goals containing non-standard `OfNat.ofNat` terms. For example, in issue
#9477, the `0` in the theorem `range_lower` has the form:
```lean
(@OfNat.ofNat
  (Std.PRange.Bound (Std.PRange.RangeShape.lower (Std.PRange.RangeShape.mk Std.PRange.BoundShape.closed Std.PRange.BoundShape.open)) Nat)
  (nat_lit 0)
  (instOfNatNat (nat_lit 0)))
```
instead of the more standard form:
```lean
(@OfNat.ofNat
  Nat
  (nat_lit 0)
  (instOfNatNat (nat_lit 0)))
```

Closes #9477
2025-07-23 04:10:21 +00:00
.github perf: minimize exported codegen data (#9356) 2025-07-22 09:05:49 +00:00
doc chore: Grove: bump version (#9419) 2025-07-17 15:02:17 +00:00
images
nix
releases_drafts
script chore: benchmark using USE_LAKE (#9361) 2025-07-17 18:44:29 +00:00
src fix: canonicalization of non-standard OfNat.ofNat terms (#9481) 2025-07-23 04:10:21 +00:00
stage0 chore: update stage0 2025-07-23 02:31:29 +00:00
tests fix: canonicalization of non-standard OfNat.ofNat terms (#9481) 2025-07-23 04:10:21 +00:00
.gitattributes
.gitignore
.gitpod.Dockerfile
.gitpod.yml
.ignore
CMakeLists.txt
CMakePresets.json
CODEOWNERS chore: Update CODEOWNERS (#9232) 2025-07-07 13:11:41 +00:00
CONTRIBUTING.md
flake.lock
flake.nix
lean-toolchain
lean.code-workspace
LICENSE
LICENSES
README.md
RELEASES.md

This is the repository for Lean 4.

About

Installation

See Setting Up Lean.

Contributing

Please read our Contribution Guidelines first.

Building from Source

See Building Lean.