Commit graph

151 commits

Author SHA1 Message Date
Leonardo de Moura
a2bcb3b73e fix: erase propositon formers, add isErasedCompatible, remove approx. from compatibleTypes 2022-09-21 20:47:02 -07:00
Leonardo de Moura
79c8a3879b fix: LCNF compatibleTypes function 2022-09-21 19:14:25 -07:00
Leonardo de Moura
917f87fee4 fix: forward declaration type 2022-09-21 18:40:38 -07:00
Leonardo de Moura
05f0a6c423 fix: skip declarations that do not have a value 2022-09-21 18:40:20 -07:00
Leonardo de Moura
a5abe864f3 chore: prepare to activate new code generator 2022-09-21 18:09:19 -07:00
Leonardo de Moura
c52203ff57 feat: add baseExt environment extension for storing code generator results 2022-09-21 18:09:19 -07:00
Leonardo de Moura
727ee79f05 fix: exponential blowup at LCNF simp 2022-09-20 17:03:40 -07:00
Leonardo de Moura
a5ac950b54 chore: increase max recursion depth for compiler 2022-09-20 16:58:45 -07:00
Leonardo de Moura
990b031871 feat: add translator attribute to MonadFVarSubst class
See new comments.
2022-09-20 16:58:27 -07:00
Leonardo de Moura
111f6a319c feat: add ppDecl'
It is useful for debugging purposes when we want to pretty print a
declaration before internalizing it.
2022-09-20 16:55:11 -07:00
Leonardo de Moura
17202d0882 fix: missing headBeta 2022-09-20 16:22:37 -07:00
Leonardo de Moura
631c216bab fix: LCNF pretty printer missing parens 2022-09-20 15:51:32 -07:00
Leonardo de Moura
4c19fdbb97 fix: normFVarImp bug 2022-09-19 21:41:18 -07:00
Leonardo de Moura
d132efd440 feat: polymorphic Code.bind 2022-09-19 21:41:18 -07:00
Mario Carneiro
ed6a5bba88 chore: rename insertAt to insertAt! 2022-09-19 13:49:20 -07:00
Leonardo de Moura
b50a3c72e9 fix: missing headBetas 2022-09-18 15:52:19 -07:00
Leonardo de Moura
4df303900b feat: apply specialize to specialized code recursively 2022-09-18 15:42:44 -07:00
Leonardo de Moura
70f615d074 fix: avoid "unknown constant" error message for auxiliary declarations 2022-09-18 15:39:58 -07:00
Leonardo de Moura
5fbe63cca4 fix: process remaining params 2022-09-18 15:29:41 -07:00
Leonardo de Moura
05145577fd feat: cache specialization results 2022-09-18 14:53:18 -07:00
Leonardo de Moura
796e9e3bdd feat: eta expand at specializeApp? 2022-09-18 13:21:55 -07:00
Leonardo de Moura
9dede6f632 feat: add mkSpecDecl 2022-09-17 17:30:57 -07:00
Leonardo de Moura
483234f30c refactor: rename Internalize.M 2022-09-17 16:46:44 -07:00
Leonardo de Moura
27c504107e feat: universe level parameter helper functions for the compiler 2022-09-17 16:29:44 -07:00
Leonardo de Moura
db6ee72aed chore: typo 2022-09-17 09:55:46 -07:00
Leonardo de Moura
3c6dee8048 fix: LCNF eta expansion bug at Simp.lean 2022-09-16 18:00:27 -07:00
Leonardo de Moura
abe1f7f6f9 feat: dependency collector for the code specializer 2022-09-15 19:55:37 -07:00
Mario Carneiro
6392c5b456 chore: import reductions 2022-09-15 14:02:38 -07:00
Leonardo de Moura
4f1f20bc97 refactor: ToExprM 2022-09-15 07:42:11 -07:00
Leonardo de Moura
c1b7accd12 refactor: LCNF local context
The previous implementation had a few issues:
- Function (and join point) declarations were being inserted into two different hashmaps.
- `borrow` information was not available for parameters.
- No proper erase functions.
2022-09-14 19:25:16 -07:00
Leonardo de Moura
9e5a818de5 fix: bug at LCNF toDecl 2022-09-14 15:23:34 -07:00
Leonardo de Moura
75f166edcc feat: add assertNoFun test 2022-09-14 13:59:09 -07:00
Leonardo de Moura
82bba1c63b feat: add Code.forM 2022-09-14 13:58:57 -07:00
Gabriel Ebner
f1b5fa53f0 chore: use new comment syntax 2022-09-14 08:26:17 -07:00
Leonardo de Moura
fccb60fb69 feat: support for [inlineIfReduce] at new compiler 2022-09-13 18:23:42 -07:00
Leonardo de Moura
e8246e026d fix: bug at compatibleTypes
Many thanks to @hargoniX
2022-09-13 15:58:06 -07:00
Leonardo de Moura
8f2ab82408 fix: bug at bindCases
Many thanks to @hargoniX
2022-09-13 15:36:46 -07:00
Leonardo de Moura
1350a57a03 refactor: remove pure field from LCNF.LetDecl
We decide that in phase 3 we will assume everything is impure, and
this kind of fine-grain tracking is not worth it.
2022-09-12 19:13:43 -07:00
Leonardo de Moura
b2d6caca0a fix: inferProjType at LCNF 2022-09-12 18:27:14 -07:00
Leonardo de Moura
506cf01d94 fix: bug at simpCasesOnCtor? 2022-09-12 16:02:19 -07:00
Leonardo de Moura
e08d48c591 feat: track ground let-declarations at Specialize.lean 2022-09-12 14:05:45 -07:00
Leonardo de Moura
ec2372e8d4 feat: add Specialize.lean skeleton 2022-09-11 20:19:44 -07:00
Leonardo de Moura
44c67f72c1 feat: add LCNF/SpecInfo.lean 2022-09-11 20:19:44 -07:00
Leonardo de Moura
54f1193739 chore: add maybeTypeFormerType 2022-09-11 20:19:44 -07:00
Leonardo de Moura
f0d75258ae feat: treat erased arguments as fixed arguments
It also renames `Lean.Expr.erased` => `Lean.Expr.isErased`
2022-09-11 20:19:44 -07:00
Leonardo de Moura
613523e1f6 feat: store borrow flag at Param
It is more robust that using `Expr.mdata`, and we save the information at `toLCNF`.
2022-09-11 20:19:44 -07:00
Leonardo de Moura
e78820e6a5 feat: add mkFixedArgMap 2022-09-11 20:19:44 -07:00
Henrik Böving
a03ea65d73 refactor: monadic compiler test framework style + new pass manager 2022-09-10 15:00:05 -07:00
Henrik Böving
c6db1099d0 feat: add occurences and phases to PassManager 2022-09-10 14:58:49 -07:00
Leonardo de Moura
ca098d3769 feat: inline applications of the form inline (f ...)
The `inline` identity function is a directive for the compiler.
2022-09-10 13:28:49 -07:00