Sebastian Ullrich
16026e9edd
perf: restore monad instance specialization hack
2021-08-12 21:09:09 +02:00
Leonardo de Moura
d482212a1c
feat: add Meta.abstract
...
closes #474
2021-08-06 18:19:06 -07:00
Leonardo de Moura
a230fe2d06
fix: forallMetaTelescope issue
...
This commit incorporates the fix at PR #612 , and clean up
`Meta/Basic.lean` using Lean 4 features.
2021-08-06 09:47:10 -07:00
Leonardo de Moura
bcfc927799
fix: fixes #602
2021-08-05 16:14:04 -07:00
Leonardo de Moura
d1d7ce1839
feat: start support for strict implicit binder annotation
2021-08-03 18:42:15 -07:00
Leonardo de Moura
6e1620ca8d
refactor: replace IO.Ref with the extern/export hack at MetaM
2021-08-03 11:50:57 -07:00
Daniel Selsam
6940166db4
chore: rebase and rm rawPos
2021-08-03 09:13:18 +02:00
Daniel Selsam
89364b802b
feat: top-down heuristic delaboration
2021-08-03 09:13:18 +02:00
Leonardo de Moura
49a87ceb4d
feat: add basic isDefEq cache
2021-07-28 16:29:44 -07:00
Leonardo de Moura
6d05daf73b
feat: add flag for allowing synthetic opaque mvars to be assigned at isDefEq
...
See issue #492
TODO: add a mechanism for detecting new metavariables.
2021-07-27 17:58:08 -07:00
Sebastian Ullrich
380c6c285a
perf: specialize some monad instances
2021-06-17 11:25:58 +02:00
Leonardo de Moura
37da993032
chore: remove HashableUSize instances
2021-06-02 08:48:11 -07:00
Leonardo de Moura
43812444a7
chore: Hashable => HashableUSize
2021-06-02 07:24:26 -07:00
Leonardo de Moura
6a87bba9c0
chore: mixHash => mixUSizeHash
2021-06-02 07:05:42 -07:00
Leonardo de Moura
a247249880
feat: add configuration option for disabling proof irrelevance at MetaM
2021-05-27 13:37:26 -07:00
Leonardo de Moura
0e1f645b07
fix: fixes #450
2021-05-10 13:55:06 -07:00
Leonardo de Moura
d68d1f0841
fix: fixes #423
2021-04-25 10:00:38 -07:00
Leonardo de Moura
aaa072cf21
feat: add withNewBinderInfos
2021-04-16 09:59:40 -07:00
Daniel Fabian
cb18af6184
feat: add withLocalDecls and withLocalDeclsD
...
They are array versions of `withLocalDecl` and `withLocalDeclD`, respectively. They are useful when you need to create variables dynamically.
2021-04-16 07:54:04 -07:00
Leonardo de Moura
2694e7798a
refactor: add MonadBacktrack
...
The new class specifies an interface for saving and restoring the
backtrackable part of the state.
This commit also fixes a few issues.
- `commitWhen` at `LevelDefEq` was defining a checkpoint for
the `isDefEq` methods, and it affects how postponed universe
constraints are handled. However, the name suggests it is
similar to `commitWhenSome?`, and consequently it was used
in other places that had nothing to do with `isDefEq`.
So, I renamed it, and provided the generic `commitWhen` at the new
`MonadBacktrack.lean` file.
- We were restoring more state then needed in a few places.
For example, we were discarding all caches.
- At `SyntheticMVars.lean`, we were using the `Meta.commitWhenSome?`
method which does not restore the `Term.State`.
2021-04-11 19:10:41 -07:00
Sebastian Ullrich
1b1ac393d8
fix: do not try to pretty-print unknown metavariables
...
Fixes #380
2021-04-08 18:16:05 +02:00
Leonardo de Moura
566fad77d4
chore: helper methods
2021-03-27 18:48:03 -07:00
Leonardo de Moura
865316bbf9
feat: improve error message when stuck solving universe constraints
...
closes #343
2021-03-11 17:46:44 -08:00
Leonardo de Moura
be841a7cad
chore: throwError! => throwError, throwErrorAt! => throwErrorAt
...
@Kha I marked the corresponding methods as `protected`.
I currently can't stand `throw_error`, and I am optimistic about
server highlighting feature you are working on :)
2021-03-11 11:59:45 -08:00
Leonardo de Moura
08fc25217d
chore: cleanup, fix docs
2021-03-07 09:01:54 -08:00
Leonardo de Moura
3850b1a9aa
perf: workaround for increasing the number of destructive updates
...
See 4908eaf396
2021-02-21 16:22:53 -08:00
Leonardo de Moura
50b6561f8f
chore: cleanup
2021-02-21 14:04:00 -08:00
Leonardo de Moura
bb2ca97df9
refactor: add options for controlling whether variables are included or not at mkLambdaFVars and mkForallFVars
2021-02-17 13:49:27 -08:00
Leonardo de Moura
761b64c929
fix: missing occursCheck at SyntheticMVars
...
fixes #301
2021-01-29 17:13:04 -08:00
Leonardo de Moura
fdab5ca835
feat: add helper methods whnfR and whnfI
2021-01-25 17:18:08 -08:00
Leonardo de Moura
b575087859
fix: unfold class projections when using TransparencyMode.instances
2021-01-25 12:30:26 -08:00
Sebastian Ullrich
0c91b3769e
chore: replace variables in src/
2021-01-22 14:36:05 +01:00
Leonardo de Moura
b6abf19656
fix: unfold abbreviations only
...
For example, we should not reduce types of the form `let x := ...; ...`
2021-01-12 08:11:04 -08:00
Leonardo de Moura
b5fdc5e364
fix: expand abbreviations at isClass?
2021-01-12 06:56:23 -08:00
Leonardo de Moura
3388c63e11
fix: typo at ParamInfo.isExplicit
2021-01-11 07:08:17 -08:00
Leonardo de Moura
5baa162713
chore: lean 3 behavior for apply
2021-01-05 12:29:29 -08:00
Leonardo de Moura
698908584b
fix: revert
2020-12-31 09:47:05 -08:00
Leonardo de Moura
78aa3d8e72
chore: use deriving BEq
2020-12-22 18:10:20 -08:00
Leonardo de Moura
3b6d65c3c3
chore: use deriving Inhabited
2020-12-13 10:09:20 -08:00
Leonardo de Moura
25ecc43a84
fix: missing try at isClass?
2020-12-09 15:19:49 -08:00
Leonardo de Moura
63ab55289e
chore: remove "liftable methods"
...
The new frontend "auto lifting" feature makes them obsolete.
2020-12-09 15:06:07 -08:00
Leonardo de Moura
72215c7144
feat: add TransparencyMode.instances
2020-11-29 18:12:33 -08:00
Leonardo de Moura
ebba9d119d
feat: unification hints
2020-11-27 18:12:49 -08:00
Leonardo de Moura
0869f38de4
chore: update structure, class, inductive
2020-11-27 15:09:30 -08:00
Leonardo de Moura
5981553e11
chore: remove workaround
2020-11-27 13:15:31 -08:00
Leonardo de Moura
c0db9f1e0c
chore: adjust stdlib to recent changes
2020-11-27 12:26:07 -08:00
Leonardo de Moura
276a8b99dd
refactor: move ppGoal to Meta
...
We need `MetaM` methods such as `isProp` to improve `ppGoal`.
This commit also moves `currNamespace` and `openDecls` to
`Core.Context`. Without this change, `Meta.ppExpr` was not taking
`open` commands into account.
2020-11-25 14:17:13 -08:00
Leonardo de Moura
d6f778bec4
refactor: arbitrary without explicit arguments
...
@Kha I was tired of writing `arbitrary _` :)
There 0 places in the stdlib where the type needs to be provided.
If in the future we need to specify the type we can use
`arbitrary (α := <type>)`
2020-11-25 09:07:38 -08:00
Leonardo de Moura
22629b3c66
feat: add headBetaMVarType
2020-11-24 16:17:27 -08:00
Leonardo de Moura
645c1034a0
chore: reduce compilation time
2020-11-23 16:18:55 -08:00