Commit graph

4780 commits

Author SHA1 Message Date
Sebastian Ullrich
3e46b8a8a4 test: simplify meta2.lean 2019-12-05 13:21:08 +01:00
Leonardo de Moura
3422dbca5f chore: fix tests 2019-12-04 17:25:46 -08:00
Leonardo de Moura
021fda2d80 chore: fix tests 2019-12-04 17:02:56 -08:00
Leonardo de Moura
827d2d7b72 chore: use mkAppN 2019-12-04 16:25:17 -08:00
Leonardo de Moura
e3b8013c4e feat: add mkAppM
This is the generic application builder.
2019-12-04 16:12:24 -08:00
Leonardo de Moura
ad54d8e024 feat: add helper functions 2019-12-04 12:43:24 -08:00
Leonardo de Moura
2664a82c32 chore: remove old test 2019-12-03 15:06:02 -08:00
Leonardo de Moura
963063dfee chore: disable tests for type class resolution prototype 2019-12-03 14:50:14 -08:00
Leonardo de Moura
9994500284 test: add more tests 2019-12-03 14:40:38 -08:00
Leonardo de Moura
43fc18eb41 fix: incorrect local context being used to create new metavariables 2019-12-03 13:31:24 -08:00
Leonardo de Moura
a7aca58bf7 fix: missing instantiateMVars 2019-12-03 13:01:44 -08:00
Leonardo de Moura
2e0b22d49d fix: MetavarContext propagation 2019-12-03 11:34:04 -08:00
Leonardo de Moura
2254da0367 test: add simple test 2019-12-03 10:42:43 -08:00
Leonardo de Moura
5adce9fa20 fix: use eta reduction at DiscrTree
@kha @dselsam

Suppose we are trying to retrieve the global instances for
`(Monad (StateM Nat))`.
During retrieval, we reducde `StateM Nat` into `fun x => StateT Nat Id x`
However, the `DiscrTree` contains an entry for `Monad (StateT * *)`.
Thus, we fail to retrieve any instance.
I fixed the particular issue by using eta reduction.
Not sure we will encounter other definitional-equality related problems .
2019-12-03 10:30:53 -08:00
Leonardo de Moura
57f830a751 chore: fix test 2019-12-02 19:42:44 -08:00
Leonardo de Moura
7e34cb4474 feat: add SynthInstance.lean
It is the first step to integrate the new type class procedure intro
`MetaM`. It implements the main entry point where we preprocess the
instance, check cache, invoke main function, process replacements, and
cache result.
2019-12-01 18:32:48 -08:00
Leonardo de Moura
00b991baf6 feat: add openAbstractMVarsResult 2019-12-01 18:32:48 -08:00
Leonardo de Moura
ef43a08b91 feat: add checkOutParam validation
It implements the approach we have discussed at
`src/library/type_context.cpp`.
2019-12-01 18:32:48 -08:00
Leonardo de Moura
f8fb195719 feat: cache local instances at metavariable declarations 2019-11-28 05:57:46 -08:00
Leonardo de Moura
be9dab41ad fix: abstractMVars 2019-11-27 10:53:25 -08:00
Leonardo de Moura
a5cf1ac5ae chore: fix tests 2019-11-26 18:07:13 -08:00
Leonardo de Moura
e45211f31c test: display discrimination tree containing type class instances 2019-11-26 18:00:31 -08:00
Leonardo de Moura
120778585d feat: add isProofQuick 2019-11-25 08:42:23 -08:00
Leonardo de Moura
882db55d11 feat: add reduce 2019-11-25 08:42:23 -08:00
Sebastian Ullrich
df3112d54d chore: fix one more benchmark 2019-11-25 12:47:42 +01:00
Sebastian Ullrich
fe3e8022a5 chore: update benchmarks 2019-11-25 10:42:14 +01:00
Leonardo de Moura
2cf3e197aa test: add getUnify basic tests 2019-11-24 08:41:00 -08:00
Leonardo de Moura
c5afa18469 feat: add DiscrTree.getMatch 2019-11-24 07:56:57 -08:00
Leonardo de Moura
4a6d0a8082 feat: projections of classes should not be reducible 2019-11-23 09:25:49 -08:00
Leonardo de Moura
c6048f0f94 feat: generalize binInsert 2019-11-23 08:20:20 -08:00
Leonardo de Moura
886eb3f51f test: add foldUnify and getUnify
These are the primitives we need for retrieving candidate instances.
2019-11-23 06:24:09 -08:00
Leonardo de Moura
30c05416a4 test: add foldMatch and getMatch
These are the primitives we need for retrieving candidate simp lemmas.
2019-11-23 06:24:03 -08:00
Leonardo de Moura
ad837950d9 test: discrimination tree prototype 2019-11-22 18:41:07 -08:00
Leonardo de Moura
69723b48c3 feat: add Array.insertAt 2019-11-22 17:42:27 -08:00
Leonardo de Moura
ea2d971bd3 chore: add isDefEq abbreviation for isExprDefEq
Most tactic users will never use `isLevelDefEq`.
2019-11-22 11:54:06 -08:00
Leonardo de Moura
7306343589 test: foApprox for isExprDefEq 2019-11-22 11:52:21 -08:00
Leonardo de Moura
a146ceafeb test: offset constraints 2019-11-22 11:19:02 -08:00
Leonardo de Moura
cff6a1d117 chore: fix tests 2019-11-22 08:03:22 -08:00
Leonardo de Moura
167549de59 chore: fix tests 2019-11-22 07:56:06 -08:00
Leonardo de Moura
617c0a8707 chore: reduce verbosity 2019-11-21 16:33:43 -08:00
Leonardo de Moura
439123e2e7 refactor: ensure that unfoldDefinitionAux is not specialized multiple times 2019-11-21 15:32:24 -08:00
Leonardo de Moura
5d7042aa9e test: add example on how to disable type checking trace messages 2019-11-21 13:08:51 -08:00
Leonardo de Moura
a28cf323b5 test: test approxDefEq 2019-11-21 11:25:27 -08:00
Leonardo de Moura
aa7afb7285 test: add ho-pattern test 2019-11-21 09:17:03 -08:00
Leonardo de Moura
67c88f12bd test: add basic test 2019-11-21 09:05:38 -08:00
Sebastian Ullrich
6df256a05e feat: import runtime
A runtime-only import is not loaded into the compile-time environment, but is linked into and initialized in binaries
2019-11-21 15:52:01 +01:00
Sebastian Ullrich
33ce758126 feat: assume A in --plugin A.so is package name and use it to synthesize initializer symbol name 2019-11-20 16:39:53 +01:00
Sebastian Ullrich
3dcd4febd9 feat: make LEAN_PATH a mapping from package names to root dirs, remove C++ impl 2019-11-20 16:39:53 +01:00
Sebastian Ullrich
ab42cffad2 refactor: rename all Default.lean files except for Init/Default.lean 2019-11-19 13:52:21 +01:00
Leonardo de Moura
0f2172fab5 chore: fix tests 2019-11-18 20:02:41 -08:00