Leonardo de Moura
7e8f9e6f66
feat(library/compiler): add [extern] attribute
2019-02-09 18:53:44 -08:00
Sebastian Ullrich
4c0f836305
chore(shell/lean): reduce lean interface to taking a single file, assuming all dependencies have already been built
2019-01-25 18:27:38 +01:00
Leonardo de Moura
c3dfb613d5
test(tests/lean/run/rc_tests): basic explicit_rc_fn tests
2019-01-17 15:25:27 -08:00
Leonardo de Moura
607d22ae58
fix(library/compiler/csimp): bug at float_cases_on_core
...
The bug occurs when floating `cases_on` application in code of the form
```
let x := C.cases_on ...
in t
```
and when the type of `t` depends on `x`.
The issue here is that the `x` declaration disappears after the float, but the resulting type still depends on it.
We fix the bug by replacing `x` with its value in the type.
cc @kha
2018-11-30 11:40:41 -08:00
Sebastian Ullrich
6d0b3afa7e
fix(library/compiler/compiler): do not silently abort on user-given sorrys
2018-11-17 18:00:55 +01:00
Leonardo de Moura
04227701d6
chore(tests/lean/run): fix the tests
...
@kha I found the real issue with these two tests.
You have modified the compiler to ignore definitions containing `sorry` :)
2018-11-15 11:21:12 -08:00
Leonardo de Moura
d0ccaa1083
chore(tests/lean): fix tests
...
TODO: `io` modifications performed yesterday may have affected `eval`.
2018-11-15 10:56:03 -08:00
Leonardo de Moura
f404c5c446
refactor(library/init/data): make sure uint* and usize are irreducible
...
Remark: this commit breaks the support for `uint*` and `usize` in the old VM.
2018-11-06 16:55:02 -08:00
Leonardo de Moura
189b037358
chore(tests/lean/run/new_compiler): fix test
2018-10-31 13:25:01 -07:00
Leonardo de Moura
28a34e798a
feat(library/compiler/csimp): projection to field
...
The new test demonstrations this transformation.
2018-10-28 09:38:45 -07:00
Leonardo de Moura
f7f981285b
chore(tests/lean/run/display_hw_term_hack_deps): remove old test
2018-10-23 11:32:56 -07:00
Leonardo de Moura
aff6d58659
chore(tests/lean/run/new_compiler): fix test
2018-10-10 18:38:18 -07:00
Leonardo de Moura
c74f4c16ca
feat(library/kernel,library/compiler/csimp): make sure nat.rec and nat.cases_on reduce when major premise is a nat literal
2018-10-10 18:35:15 -07:00
Leonardo de Moura
338038a05e
feat(library/init/core): add inline identity function
2018-10-10 18:17:29 -07:00
Leonardo de Moura
124b4d37fe
feat(library/compiler): port simp_inductive to the new compiler stack
...
This commit also fixes a bug in the old `simp_inductive` module, and
removes now obsolete files (`compiler_step_visitor` and `old_util`).
2018-10-08 16:58:43 -07:00
Leonardo de Moura
b3451fb682
perf(library/init/lean/parser/parsec): merge ok and ok_eps
2018-09-27 15:14:37 -07:00
Leonardo de Moura
017261960c
feat(library/compiler/csimp): add float_cases_on
2018-09-24 18:10:26 -07:00
Leonardo de Moura
52d1abf0bc
feat(library/compiler): add cse to new compiler stack
2018-09-14 17:48:18 -07:00
Leonardo de Moura
e8ab46619b
chore(tests/lean/run/new_compiler): fix test
2018-09-14 16:42:53 -07:00
Leonardo de Moura
7174d53820
feat(library/compiler/csimp): distribute application over cases
2018-09-14 15:14:40 -07:00
Leonardo de Moura
31a9a22641
test(tests/lean/run/new_compiler): add test
2018-09-14 13:35:41 -07:00
Leonardo de Moura
5ed05db261
test(tests/lean/run/new_compiler): add test for new compiler stack
2018-09-14 09:46:02 -07:00
Leonardo de Moura
afd54039ab
chore(library): remove >>, we should use *>
2018-09-12 17:31:21 -07:00
Leonardo de Moura
9e305a5f26
chore(library): remove return, we should use pure
2018-09-12 16:51:11 -07:00
Leonardo de Moura
ab9e812ac5
chore(tests/lean): fix tests
2018-09-06 18:09:32 -07:00
Leonardo de Moura
208b932583
feat(library/constructions/brec_on): add brec_on and binduction_on for new inductive datatype module
...
We don't support these constructions for nested inductive types, but we
do for mutual inductives.
2018-09-05 14:46:03 -07:00
Leonardo de Moura
f335623530
feat(library/constructions/brec_on): add below and ibelow for new inductive datatype module
2018-09-05 14:46:03 -07:00
Leonardo de Moura
afb9584a63
feat(kernel): store at inductive_val whether the type is reflexive or not
2018-09-05 14:46:03 -07:00
Leonardo de Moura
4964ad660f
feat(library/constructions/no_confusion): add no_confusion for new inductive datatype module
2018-09-05 10:27:49 -07:00
Leonardo de Moura
4773a3be5f
feat(library/constructions/no_confusion): add no_confusion_type for new inductive datatype module
2018-09-05 09:55:13 -07:00
Leonardo de Moura
cc5f60c28d
test(tests/lean/run/new_inductive): add new tests
2018-09-04 18:17:13 -07:00
Leonardo de Moura
d8e7941116
feat(library/constructions/rec_on): add rec_on for new inductive datatype module
2018-09-04 17:22:16 -07:00
Leonardo de Moura
0f207380c7
test(tests/lean/run/new_inductive): add test for new inductive datatype module
2018-09-04 10:35:28 -07:00
Leonardo de Moura
69734dfb3a
chore(tests/lean): fix tests
2018-08-23 13:49:07 -07:00
Sebastian Ullrich
adfc8c9e62
chore(tests/lean/run/deriv): fix test
2018-08-23 10:38:59 -07:00
Sebastian Ullrich
6009279ab3
fix(library/compiler/cse): deactivate CSE for constructor applications
...
Fixes 1968
2018-08-22 14:32:03 -07:00
Sebastian Ullrich
6dbe54a01b
chore(library/init/io): rename io.print_ln to io.println
2018-08-21 08:43:10 -07:00
Sebastian Ullrich
3516c37ec9
feat(library/init/control/coroutine_io): coroutine_io
2018-08-21 08:43:10 -07:00
Sebastian Ullrich
6b55e24ab7
feat(library/init/{io,control/except}): use lift_t to automatically upcast io and other errors
2018-08-21 08:43:09 -07:00
Sebastian Ullrich
9db688f4c2
fix(library/{vm/vm_io,init/io}): fix bugs and tests
2018-08-21 08:43:09 -07:00
Sebastian Ullrich
37e5f03351
refactor(library/system/io): move into init
2018-08-21 08:43:09 -07:00
Leonardo de Moura
8a96fde229
feat(library/init/control/coroutine): add coroutine
...
Remark: the termination proofs are commented because Lean 4 is
currently ignoring them and accepting non-terminating functions.
These files are based on an experiment implemented using Lean 3.
We can find it here:
https://gist.github.com/leodemoura/f5d82426c105b5fae0880e77024f6e9c
We will use coroutines to implement the interaction between reader,
elaborator and main driver.
2018-08-12 17:14:02 -07:00
Sebastian Ullrich
2823bebd23
refactor(library/init/lean/parser/parsec): message.pos: replace with iterator
...
This allows efficient recovery from a parse error as well as implementing
`has_to_string` for `message`
2018-07-30 10:38:00 -07:00
Sebastian Ullrich
10b18e77a1
feat(library/init/lean/parser/reader/basic): combinators: create partial syntax trees
2018-07-27 16:19:02 -07:00
Sebastian Ullrich
65fd050b83
feat(library/init/lean/parser/parsec): add custom error message type
2018-07-27 14:29:50 -07:00
Sebastian Ullrich
72b255d4e1
chore(library/init/lean/parser/parser_t): rename module and type to parsec to avoid nested use of parser
2018-07-12 10:35:20 +02:00
Sebastian Ullrich
e57117a9b3
chore(library/init/lean/parser/parser_t): revert introduction of parser_t
2018-07-11 18:44:04 +02:00
Sebastian Ullrich
f31e5f407f
chore(tests/lean/run/handlers): fix test
2018-06-29 16:39:47 +02:00
Sebastian Ullrich
7ae87705c2
feat(library/init/lean/parser/parser_t): introduce monad_parser
2018-06-15 17:48:20 +02:00
Leonardo de Moura
71fc35af1d
chore(library/vm): remove meta rb_map
...
We should use the non-meta rbmap that is implemented in Lean.
2018-06-14 17:34:43 -07:00