Commit graph

530 commits

Author SHA1 Message Date
Leonardo de Moura
e84f7744c3 feat(library/init/lean/compiler/const_folding): const fold nat.succ and char.of_nat 2019-02-16 11:15:19 -08:00
Leonardo de Moura
61274c7d35 feat(library/init/data/char): use uint32 instead of nat for defining char 2019-02-15 18:07:55 -08:00
Leonardo de Moura
e0fd89e165 feat(library/init/lean/compiler): fold nat predicates 2019-02-15 16:17:16 -08:00
Leonardo de Moura
0cb3ac683d feat(library/compiler): connect new const_folding module implemented in Lean with csimp 2019-02-15 14:37:48 -08:00
Leonardo de Moura
6785ad9844 fix(library/init/lean/default): missing file 2019-02-14 15:21:53 -08:00
Leonardo de Moura
390c9009f7 chore(shell,boot): update boot, and initialization process 2019-02-14 14:49:16 -08:00
Leonardo de Moura
68e8aa8d1d feat(library/init/lean/compiler): add constant folding helper functions 2019-02-14 14:35:10 -08:00
Leonardo de Moura
5e7308d22d chore(library/init/lean/expr): get_app_fn 2019-02-14 14:12:25 -08:00
Sebastian Ullrich
587a7a001a feat(library/init/lean/elaborator): to_pexpr: support string literals 2019-02-14 14:07:05 -08:00
Sebastian Ullrich
dbc470d7e4 feat(library/init/lean/{parser/term,elaborator}): support @& borrowed annotations 2019-02-14 14:07:05 -08:00
Sebastian Ullrich
7cffe6935e feat(frontends/lean/vm_elaborator): port to new runtime 2019-02-14 14:07:05 -08:00
Leonardo de Moura
9cb2005e8e feat(library/init/lean): add hash functions and dbg_to_string 2019-02-13 16:19:25 -08:00
Leonardo de Moura
b89eb64cf1 refactor(library/init/lean/expr): use native constructors 2019-02-13 15:07:49 -08:00
Leonardo de Moura
71f5290567 feat(kernel): expose level primitives 2019-02-13 10:37:13 -08:00
Leonardo de Moura
4627929a83 refactor(boot,runtime,util): move name runtime implementation to util/name, and use "extern C" ABI 2019-02-13 08:27:23 -08:00
Leonardo de Moura
f20c132ced feat(library/init/lean/elaborator): use extern attribute 2019-02-12 11:40:21 -08:00
Sebastian Ullrich
534b507aff feat(library/init/lean/frontend): rework error reporting 2019-02-12 13:34:32 +01:00
Leonardo de Moura
5a5e949578 feat(library/init/lean/name): use extern attribute 2019-02-11 16:12:25 -08:00
Leonardo de Moura
bc4e06666b chore(*): avoid 0-ary extern declarations 2019-02-11 13:21:17 -08:00
Leonardo de Moura
7e8f9e6f66 feat(library/compiler): add [extern] attribute 2019-02-09 18:53:44 -08:00
Leonardo de Moura
e8758a1707 chore(library/compiler/export_attribute): exporting constructors is messy
It is much simpler and only slightly more verbose to export an
auxiliary function that just invokes the constructor.
2019-02-09 18:00:27 -08:00
Sebastian Ullrich
b809bb5311 feat(library/init/lean/frontend): demangle and remove read_file 2019-02-09 19:55:53 +01:00
Leonardo de Moura
b50f9de3b8 feat(library/init/lean/extern): declare extern_attr_data and helper functions 2019-02-08 16:55:44 -08:00
Sebastian Ullrich
f9b3244d97 fix(library/init/lean/expr): literal: use C++ constructor ordering 2019-02-07 13:03:09 +01:00
Leonardo de Moura
2058d33d07 feat(runtime,library/compiler): add name.dec_eq builtin 2019-02-05 14:36:02 -08:00
Sebastian Ullrich
a823157338 fix(library/init/lean/expander): fix let expansion again
Last bug in core.lean!
2019-01-22 11:16:00 +01:00
Sebastian Ullrich
0846cc2aa0 fix(library/init/lean/elaborator): to_level 2019-01-22 11:16:00 +01:00
Sebastian Ullrich
9f90dbfd3d feat(library/init/lean/parser/syntax): improve syntax.get_pos for more error positions 2019-01-22 11:16:00 +01:00
Sebastian Ullrich
099354eb5f fix(library/init/lean/expander): expansion of parameterized let 2019-01-21 22:07:10 +01:00
Sebastian Ullrich
814ceb43fe fix(library/init/lean/parser/declaration): axiom, constant, what's the difference 2019-01-21 18:09:26 +01:00
Sebastian Ullrich
abf60e3242 feat(library/init/lean/elaborator): include 2019-01-21 18:09:18 +01:00
Sebastian Ullrich
53d9cb5358 fix(library/init/lean/elaborator): resolve idents after 'attribute' 2019-01-21 17:47:17 +01:00
Sebastian Ullrich
c22fbb5cde feat(library/init/lean,frontends/lean/vm_elaborator): set_option 2019-01-20 18:21:41 +01:00
Sebastian Ullrich
88534abccd fix(library/init/lean/expander): tuple element order 2019-01-20 16:41:46 +01:00
Sebastian Ullrich
b24796d98e feat(library/init/lean/elaborator): inaccessible 2019-01-20 16:41:33 +01:00
Sebastian Ullrich
69e363446d fix(library/init/lean/{parser/term,elaborator}): local notations override previous notations 2019-01-20 16:25:15 +01:00
Sebastian Ullrich
05bf392385 fix(library/init/lean/frontend): parser error positions 2019-01-20 16:24:12 +01:00
Sebastian Ullrich
fc7acc9898 fix(library/init/lean/elaborator): choice 2019-01-20 14:39:22 +01:00
Sebastian Ullrich
dcd3b3dc5d fix(library/init/lean/elaborator): section variables need to be preresolved as well
In
```
section binary
variables {α : Type u} {β : Type v}
variable f : α → α → α
local infix * := f
def commutative        := ∀ a b, a * b = b * a
end binary
```
the expansion of `*` applies a macro scope to `f`, so we need to resolve it
before that
2019-01-20 13:22:08 +01:00
Sebastian Ullrich
1708fc74f8 fix(library/init/lean/elaborator): structure instances 2019-01-19 15:35:11 +01:00
Sebastian Ullrich
a23df570fc fix(library/init/lean/elaborator): match 2019-01-17 19:57:00 +01:00
Sebastian Ullrich
3e8e823893 fix(frontends/lean/vm_elaborator): preserve internal name of section variables 2019-01-17 19:57:00 +01:00
Sebastian Ullrich
85cad3a7f1 fix(library/init/lean/elaborator): equation heads 2019-01-17 19:57:00 +01:00
Sebastian Ullrich
8cc35b854b feat(library/init/lean/{expander,elaborator}): variable(s) 2019-01-17 17:06:52 +01:00
Sebastian Ullrich
0923a2cbae refactor(library/init/lean/elaborator): avoid deprecated expr locals in new elaborator state 2019-01-17 12:29:44 +01:00
Sebastian Ullrich
c338245536 feat(library/init/lean/elaborator): implement the only part of open/export 2019-01-16 19:49:44 +01:00
Sebastian Ullrich
13781ed114 feat(library/init/lean/parser/token): numeric literals of more exotic bases 2019-01-16 19:39:30 +01:00
Sebastian Ullrich
2c4b566038 feat(frontends/lean/vm_elaborator): implement equations 2019-01-16 19:12:40 +01:00
Sebastian Ullrich
a6d5af7387 feat(library/init/lean/expander): expand class and class inductive 2019-01-16 19:12:40 +01:00
Sebastian Ullrich
246eecf155 fix(library/init/lean/elaborator): do not mangle attribute names (since they are not environment identifiers) 2019-01-16 19:12:40 +01:00