Lean 4 fork for HoTT-compatible kernel extensions (Path types, transport, HITs). Maintained against upstream leanprover/lean4.
Find a file
Leonardo de Moura e6a98ffe9c feat(library/type_context): improve unifier first-order approximation
@kha We can now solve unification constraints of the form

         ?m unit =?= itactic

I'm not very confident this new extension will improve usuability
instead of creating new counter-intuitive behavior.
At least, in the process of implementing it, I fixed two bugs,
and removed a nasty hack that was being used in the unifier.
Thus, even if we disable this feature in the future, some good came out
of it.

Although, the new extension locally increases the number of constraints
that can be solved, it may prevent terms that could be elaborated before
from being elaborated. I am not too concerned at this point because
I could not construct a natural example. I encountered one case, but it
was due to a problem that I fixed in the previous commit.
I reconstruct it here for the record. Suppose we have a constraint

         ?m_1 ?m_2 =?= itactic

Without the fix from the previous commit, `itactic` would unfold too
`id_rhs Type (tactic unit)`, and the constrain would be solved as

         ?m_1 := (id_rhs Type)
         ?m_2 := (tactic unit)

It succeeds locally, but the elaboration fails later when it tries to
synthesize the type class `has_bind (id_rhs Type)`.
The previous fixes the problem by making sure `itactic` is unfolded to
`tactic unit` as expected. `id_rhs` is an auxiliary definition
used to implement smart unfolding. That being said, the user could in
principle define `itactic` as `@id Type (tactic unit)`, and the constraint

         ?m_1 ?m_2 =?= itactic

will be solved as

         ?m_1 := (@id Type)
         ?m_2 := (tactic unit)

which is not the solution we want.
2018-01-30 15:42:17 -08:00
.github chore(.github/CONTRIBUTING): fix typos and URLs 2017-10-30 16:23:22 +01:00
bin chore(bin/lean-gdb): add pretty printer for lean::level 2017-11-30 17:47:49 +01:00
doc refactor(library/io): make io easier to extend and use 2018-01-23 15:03:31 -08:00
extras/latex chore(extras/depgraph): remove leandeps 2017-07-15 02:27:17 -07:00
images
leanpkg refactor(library/io): make io easier to extend and use 2018-01-23 15:03:31 -08:00
library fix(library/init/data/setoid): fix redundant parameter 2018-01-28 15:49:35 -08:00
packages chore(script/test_registry): Replace with leanpkg. Execute in every artifact-producing build configuration. 2017-12-20 14:01:45 -08:00
script chore(script/test_registry): Replace with leanpkg. Execute in every artifact-producing build configuration. 2017-12-20 14:01:45 -08:00
src feat(library/type_context): improve unifier first-order approximation 2018-01-30 15:42:17 -08:00
tests feat(library/type_context): improve unifier first-order approximation 2018-01-30 15:42:17 -08:00
tmp feat(library/init/data): start rbtree module 2017-11-15 16:17:39 -08:00
.appveyor.yml chore(script/test_registry): Replace with leanpkg. Execute in every artifact-producing build configuration. 2017-12-20 14:01:45 -08:00
.clang-format feat(library/vm/process): add basic process support 2017-03-28 18:08:06 -07:00
.codecov.yml fix(.codecov.yml): do not fail github ci if coverage drops by 0.01% 2017-06-25 10:35:02 +02:00
.gitattributes chore(.gitattributes): use union merge strategy for doc/changes.md 2017-12-11 12:49:10 +01:00
.gitignore fix(build): fix Cygwin build 2018-01-22 18:07:04 -08:00
.travis.yml fix(.travis.yml): support combining $TEST_LEANPKG_REGISTRY and $UPLOAD 2017-12-22 11:54:29 +01:00
LICENSE
README.md chore(doc/make): add platform-generic build instructions 2018-01-23 11:14:18 -08:00

logo

LicenseWindowsLinux / macOSTest CoverageChat
Codecov Join the gitter chat

About

Installation

Stable and nightly binary releases of Lean are available on the homepage. For building Lean from source, see the build instructions.

Miscellaneous

Roadmap