Lean 4 fork for HoTT-compatible kernel extensions (Path types, transport, HITs). Maintained against upstream leanprover/lean4.
Find a file
Joachim Breitner 439c3c5544
refactor: make exportEntriesFnEx return all olean levels at once (#13142)
This PR replaces the per-level `OLeanLevel → Array α` return type of
`exportEntriesFnEx` with a new `OLeanEntries (Array α)` structure that
bundles exported, server, and private entries together. This allows
extensions to share expensive computation across all three olean levels
instead of being called three separate times.

A new `computeExtEntries` function in `Environment.lean` calls each
extension's export function once and distributes results across levels.
`mkModuleData` accepts optional pre-computed entries, and `writeModule`
uses `computeExtEntries` to compute once for all three olean parts.

Extensions that previously relied on `env.setExporting` being
pre-applied by `mkModuleData` now call `env.setExporting true`
internally for their exported/server-level filtering, since the export
function is called once rather than per-level.

Extracted from #13117 to be reviewed independently.

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-27 08:57:45 +00:00
.claude chore: speed up test suite slightly (#12969) 2026-03-20 12:24:32 +00:00
.github fix: rebootstrap cache in github CI (#13143) 2026-03-26 20:50:03 +00:00
.vscode chore: replace workspace file with .vscode/ settings (#12770) 2026-03-04 01:10:04 +00:00
doc feat: unfold and rewrap instances in inferInstanceAs and deriving 2026-03-22 13:25:46 +01:00
images
releases_drafts
script chore: remove lean4checker from release repos (#13121) 2026-03-26 12:15:37 +00:00
src refactor: make exportEntriesFnEx return all olean levels at once (#13142) 2026-03-27 08:57:45 +00:00
stage0 chore: update stage0 2026-03-27 01:15:51 +00:00
tests refactor: simplify grind canonicalizer and fix preprocessing issues (#13149) 2026-03-27 05:00:01 +00:00
.gitattributes chore: migrate more tests to new test suite (#12809) 2026-03-06 16:52:01 +00:00
.gitignore chore: replace workspace file with .vscode/ settings (#12770) 2026-03-04 01:10:04 +00:00
.gitpod.Dockerfile
.gitpod.yml
.ignore
CMakeLists.txt chore: make leantar available in stage0 (#12992) 2026-03-19 20:43:43 +00:00
CMakePresets.json
CODEOWNERS
CONTRIBUTING.md chore: migrate pkg tests (#12889) 2026-03-11 18:55:46 +00:00
flake.lock
flake.nix chore: add aarch64-darwin to flake (#12915) 2026-03-18 15:55:34 +00:00
lean-toolchain
LICENSE
LICENSES feat: bundle leantar with Lean (#12822) 2026-03-09 20:10:59 +00:00
README.md
RELEASES.md

This is the repository for Lean 4.

About

Installation

See Install Lean.

Contributing

Please read our Contribution Guidelines first.

Building from Source

See Building Lean.