Lean 4 fork for HoTT-compatible kernel extensions (Path types, transport, HITs). Maintained against upstream leanprover/lean4.
This PR ports Batteries.WF to Init.WFC for executable well-founded fixpoints. It introduces `csimp` theorems to replace the recursors and non-executable definitions with executable definitions. This ocassionally comes up on Zulip as it prevents admiting definitions generated from well-founded induction. (e.g., [#lean4 > Computable WellFounded.fix](https://leanprover.zulipchat.com/#narrow/channel/270676-lean4/topic/Computable.20WellFounded.2Efix/with/529347861) and [#mathlib4 > Why Nat.find is computable, when Wellfounded.fix isn't?](https://leanprover.zulipchat.com/#narrow/channel/287929-mathlib4/topic/Why.20Nat.2Efind.20is.20computable.2C.20when.20Wellfounded.2Efix.20isn't.3F/with/545143617)). This was motivated by running into poor elaboration performance with recursive definitions involving complex inductive types generated by a custom elaborator. It would be helpful to explore bypassing the elaborator and generating elaborated terms directly, but this requires an executable fixpoint (such as `WellFounded.fixC` introduced in batteries). |
||
|---|---|---|
| .claude | ||
| .github | ||
| doc | ||
| images | ||
| releases_drafts | ||
| script | ||
| src | ||
| stage0 | ||
| tests | ||
| .gitattributes | ||
| .gitignore | ||
| .gitpod.Dockerfile | ||
| .gitpod.yml | ||
| .ignore | ||
| CMakeLists.txt | ||
| CMakePresets.json | ||
| CODEOWNERS | ||
| 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
- Quickstart
- Homepage
- Theorem Proving Tutorial
- Functional Programming in Lean
- Documentation Overview
- Language Reference
- Release notes starting at v4.0.0-m3
- Examples
- External Contribution Guidelines
Installation
See Install Lean.
Contributing
Please read our Contribution Guidelines first.
Building from Source
See Building Lean.