Commit graph

17833 commits

Author SHA1 Message Date
Leonardo de Moura
5d9f3f6fba chore: add ambiguity comment 2019-11-08 08:28:31 -08:00
Daniel Selsam
19ec5cda13 doc: typeclass loop issue and suggestions 2019-11-08 08:28:26 -08:00
Leonardo de Moura
583923492c chore: naming conventions 2019-11-07 10:40:26 -08:00
Leonardo de Moura
b8b31552d1 chore: update stage0 2019-11-07 10:28:13 -08:00
Leonardo de Moura
322f18f0c9 chore: WHNFUtil => WHNF 2019-11-07 10:25:58 -08:00
Daniel Selsam
f272f42c1f fix: (throwaway) context was ignoring const levels 2019-11-07 10:21:24 -08:00
Leonardo de Moura
91e87a0cd4 feat: add reference implementation for whnf 2019-11-07 10:20:15 -08:00
Leonardo de Moura
e020cd2ea0 refactor: parametrize over getConst : Name -> m (Option (ConstantInfo)) instead of env : Environment
Motivation: when instatiating these templates, we can make definitions
opaque by returning `none` at `getConst`.
2019-11-07 10:20:15 -08:00
Leonardo de Moura
a087aea871 chore: remove special support for user-facing projection functions
We now have kernel projections, and user-facing projection functions
are defined using them. So, we don't need special support anymore for
them. They are just regular functions in Lean4.
2019-11-07 10:20:15 -08:00
Leonardo de Moura
05c125c938 chore: remove dead code 2019-11-07 10:20:15 -08:00
Leonardo de Moura
65d14ed1d3 feat: add smart unfolding 2019-11-07 10:20:15 -08:00
Leonardo de Moura
cbf09b44ea feat: add getStuckMVar 2019-11-07 10:20:14 -08:00
Leonardo de Moura
069a18fe17 chore: update stage0 2019-11-07 10:20:14 -08:00
Leonardo de Moura
3faa033705 refactor: add parametric whnfCore
Motivation: `WHNFUtil` will provide a parametric implementation for
WHNF. We will use it to implement `TypeUtil` and `matchPattern`.
2019-11-07 10:20:14 -08:00
Leonardo de Moura
eeb865c97c chore: merge QuotUtil and InductiveUtil into WHNFUtil 2019-11-07 10:20:14 -08:00
Sebastian Ullrich
68a126be3f chore: update benchmark packages 2019-11-07 17:47:58 +01:00
Sebastian Ullrich
fef586627a chore: revert "chore: switch back to clang 8"
This reverts commit bffc55219e.
2019-11-07 10:45:59 +01:00
Daniel Selsam
3b6755dea1 doc: namespace A.B vs namespace A namespace B 2019-11-06 10:16:33 -08:00
Daniel Selsam
7cddeaa0d3 doc: tc triggers nested tc, potentially with tmp metavar leak 2019-11-06 10:15:05 -08:00
Sebastian Ullrich
cf381f68b7 chore: revert "chore: call ctest with -V"
This reverts commit 6a34b20540.
2019-11-06 10:13:52 -08:00
Sebastian Ullrich
d8bb4df96f chore: revert "chore: add std::cout.flush"
This reverts commit a43a225013.
2019-11-06 10:13:39 -08:00
Sebastian Ullrich
fdccf9ad14 chore: revert "chore: publish test artifacts to debug CI failures"
This reverts commit 3c476b4278.
2019-11-06 10:13:20 -08:00
Sebastian Ullrich
2240a349d0 chore: update-stage0: stage all files
This makes it much harder to accidentally forget to commit files for new modules

/cc @leodemoura
2019-11-06 10:11:23 -08:00
Leonardo de Moura
2a53597035 doc: new MetavarContext requirements and design 2019-11-06 10:03:04 -08:00
Leonardo de Moura
94cddc299d chore: update stage0 2019-11-05 18:57:07 -08:00
Leonardo de Moura
e844a5be74 feat: simplify MetavarContext
Remove `AbstractMetavarContext` and `TmpMetavarContext`.
Disable `TypeUtil` until we decide this is the right design.

Using very simple approach:
- No distinction betwen temporary and regular metavariables.
- Metavariables have a `depth` Nat field.
- MetavarContext also has a `depth` field.
- We bump the `MetavarContext` depth when we create a nested problem.
  Example: Elaborator (depth = 0) -> Simplifier matcher (depth = 1) -> TC (level = 2) -> TC (level = 3) -> ...
- When MetavarContext is at depth N, isDefEq does not assign variables from depth < N.
- Metavariables from depth N+1 must be fully assigned before we return to level N.
- New design even allows us to invoke tactics from TC.

cc @dselsam
2019-11-05 18:44:33 -08:00
Leonardo de Moura
41e574d6cc chore: fix tests 2019-11-05 14:44:05 -08:00
Leonardo de Moura
c3e9ac73e2 refactor: default ==> arbitrary
Make sure it is opaque, and avoid `irreducible`
2019-11-05 14:42:42 -08:00
Leonardo de Moura
06fe9d3afa refactor: EState ==> EStateM 2019-11-05 09:05:10 -08:00
Leonardo de Moura
5bb5ef6296 refactor: State ==> StateM 2019-11-05 07:56:19 -08:00
Leonardo de Moura
cb554d6473 chore: remove unnecessary configuration option 2019-11-04 05:32:45 -08:00
Leonardo de Moura
cf17fbb8e9 chore: missing @[specialize] 2019-11-04 03:59:39 -08:00
Leonardo de Moura
1bf1290570 feat: use kernel projections in constructions
Motivation: auxiliary recursors such as `brecOn` do not depend on
user-facing projection definitions anymore.
Thus, we can simplify `whnfCore` at `TypeUtil`.
2019-11-04 03:38:57 -08:00
Leonardo de Moura
4cfa4f0e9c feat: add temporary hack
`mutual` + `partial` doesn't work yet.
2019-11-03 15:35:15 -08:00
Leonardo de Moura
b181ee5a4c chore: typos 2019-11-02 14:45:17 -07:00
Leonardo de Moura
146aa71886 feat: reduce auxiliary recursors 2019-11-02 14:38:24 -07:00
Leonardo de Moura
f8c5face56 chore: update 2019-11-02 12:12:27 -07:00
Leonardo de Moura
ba7f2849dc chore: use aux recursor extension implemented in Lean 2019-11-02 11:48:02 -07:00
Leonardo de Moura
1702579a76 chore: update stage0 2019-11-02 11:27:50 -07:00
Leonardo de Moura
359a78b902 feat: aux recursor extension in Lean 2019-11-02 11:24:52 -07:00
Leonardo de Moura
2d01621aba feat: add TagDeclarationExtension helper 2019-11-02 10:59:06 -07:00
Leonardo de Moura
1a5de2c184 feat: add reduceProjectionFn
This is code for reducing user-facing projections functions created by
the `structure` command.
2019-11-02 10:26:38 -07:00
Leonardo de Moura
2d65b2ba9f feat: reduce Expr.proj 2019-11-01 17:07:38 -07:00
Leonardo de Moura
638ceebab4 feat: helper functions 2019-11-01 17:07:26 -07:00
Leonardo de Moura
36f2bc987e chore: TypeInference ==> TypeUtil 2019-11-01 16:24:49 -07:00
Leonardo de Moura
b3bce21e3b feat: use CPS 2019-11-01 16:22:55 -07:00
Leonardo de Moura
1631fbde37 feat: add support for reducing recursor applications 2019-11-01 10:27:39 -07:00
Leonardo de Moura
823221840a feat: add matchConst helper function 2019-11-01 10:20:34 -07:00
Leonardo de Moura
68bbba365c feat: add isQuotRecStuck 2019-11-01 10:03:46 -07:00
Leonardo de Moura
cc6a72b789 feat: add reduceQuotRecAux 2019-11-01 09:55:29 -07:00