v4.1.0-rc1
Pre-releaseThis is the first release candidate for v4.1.0-rc1
. We are switching to using a tracking branch for this release, at release/v4.1.0
. We hope to cherry-pick any critical fixes onto this branch, rather than moving up to master for any subsequent release candidates.
Breaking changes since v4.0.0
:
-
After elaborating a configuration file, Lake will now cache the configuration to a
lakefile.olean
. Subsequent runs of Lake will import this OLean instead of elaborating the configuration file. This provides a significant performance improvement (benchmarks indicate that using the OLean cuts Lake's startup time in half), but there are some important details to keep in mind:- Lake will regenerate this OLean after each modification to the
lakefile.lean
orlean-toolchain
. You can also force a reconfigure by passing the new--reconfigure
/-R
option tolake
. - Lake configuration options (i.e.,
-K
) will be fixed at the moment of elaboration. Setting these options whenlake
is using the cached configuration will have no effect. To change options, runlake
with-R
/--reconfigure
. - The
lakefile.olean
is a local configuration and should not be committed to Git. Therefore, existing Lake packages need to add it to their.gitignore
.
- Lake will regenerate this OLean after each modification to the
-
The signature of
Lake.buildO
has changed,args
has been split intoweakArgs
andtraceArgs
.traceArgs
are included in the input trace andweakArgs
are not. See Lake's FFI example for a demonstration of how to adapt to this change. -
The signatures of
Lean.importModules
,Lean.Elab.headerToImports
, andLean.Elab.parseImports
have changed from takingList Import
toArray Import
. -
There is now an
occs
field in the configuration object for therewrite
tactic, allowing control of which occurrences of a pattern should be rewritten. This was previously a separate argument forLean.MVarId.rewrite
, and this has been removed in favour of an additional field ofRewrite.Config
. It was not previously accessible from user tactics.