Leonardo de Moura
4836dd55b5
chore(frontends/lean): propogate position information
...
This is a huge HACK to get some position information.
2018-06-08 11:12:01 -07:00
Leonardo de Moura
818170d780
refactor(kernel): remove tag from kernel expressions
...
We are temporarily storing position information in a global table.
2018-06-08 10:29:22 -07:00
Leonardo de Moura
2a79da1ab6
refactor(kernel): move formatting stuff out of the kernel
2018-06-07 16:28:54 -07:00
Leonardo de Moura
ddf1c89e76
chore(kernel/abstract): remove mk_binding cache
2018-06-07 16:28:54 -07:00
Leonardo de Moura
6333043adf
refactor(kernel): abstract_local(s) ==> abstract
2018-06-07 16:28:54 -07:00
Leonardo de Moura
c0e1d05199
chore(kernel): type_checker ==> old_type_checker
2018-06-06 16:10:40 -07:00
Leonardo de Moura
3c1ccc9b74
refactor(kernel): use m_meta instead of m_trusted
2018-05-31 11:18:00 -07:00
Leonardo de Moura
75c63ec921
refactor(*): list<name> ==> obj_list<name>
2018-05-23 15:48:43 -07:00
Leonardo de Moura
4af1f31877
feat(util, kernel): add obj_list wrapper for Lean list objects, and use it to implement list of universe levels
2018-05-23 14:48:22 -07:00
Leonardo de Moura
d92679f969
refactor(*): replace name with lean.name
2018-05-20 09:42:44 -07:00
Leonardo de Moura
a52b418452
refactor(*): mk sure old name has same shape of new lean.name type
2018-05-20 08:48:48 -07:00
Leonardo de Moura
0556412f8d
refactor(*): add runtime folder
...
@kha The runtime folder includes what is needed to link a
standalone Lean program. It is still contains some unnecessary files.
We will be able to remove them after we release Lean4.
2018-05-14 14:23:56 -07:00
Leonardo de Moura
c08a3bc557
refactor(library/typed_expr): move typed_expr to frontends/lean
2018-04-09 15:25:40 -07:00
Leonardo de Moura
97ed299ce4
chore(frontends/lean/util): remove dead function
2018-01-30 12:48:48 -08:00
Leonardo de Moura
c5df94ed17
feat(library/tactic): add support for auto params at simp tactic
2018-01-11 16:47:22 -08:00
Sebastian Ullrich
716c730c38
fix(frontends/lean/structure_cmd): allow extending structures in the current context
2017-10-23 11:12:14 -07:00
Gabriel Ebner
c15f2979c6
fix(frontends/lean/util): allow docstrings after variables
2017-08-01 10:18:05 +01:00
Leonardo de Moura
9afb53fad5
feat(kernel/expr): allow metavariables to have user-facing names
...
We need this feature for:
1) Defining nonlinear search patterns. Example: (?m <= ?m + 1)
2) Preprocessing recursive equations and support the pattern
refinement approach used in Agda. Example: in Agda, they accept
```
def append {A : Type} : Π (m n : nat), Vec A m -> Vec A n -> Vec A (m + n)
| m n nil ys := ys
| m n (cons m' x xs) ys := cons x (append m' n xs ys)
```
These equations have to be refined. For example, `m` has to be
replaced with `0` (in the first equation), and `succ m'` in the
second. To implement this kind of refinement, we need to convert
the pattern variables (local constants) into metavariables during
elaboration. Then, the unassigned metavariables become local constants
again. This preprocessing step will fix some of the issues on #1594 .
To completely fix #1594 , we will need yet another preprocessing step
which will implement "complete transition" used in the equation
compiler before we start elim_match.cpp
2017-07-16 07:16:41 -07:00
Leonardo de Moura
096b437c11
fix(library/equations_compiler, frontends/lean): missing operator== for macro_definition_cell subclasses
2017-06-22 16:13:29 -07:00
Leonardo de Moura
55c8627f2c
feat(frontends/lean): {! ... !} takes a list of pre-terms
2017-06-13 22:19:17 -07:00
Leonardo de Moura
603bbe5987
fix(*): gcc 7 linking errors
2017-05-31 16:35:09 -07:00
Leonardo de Moura
62c24f9bb5
chore(*): remove pos_num and num from stdlib
2017-05-25 18:24:16 -07:00
Sebastian Ullrich
cd013f22c0
chore(*): replace "'^.' notation" with "field notation", pretty print using "."
2017-03-31 09:40:49 -07:00
Sebastian Ullrich
add8836ab2
fix(frontends/lean/{elaborator,parser}): use position of '.' for field notation position
...
Note that flycheck will still highlight the entire word...
2017-03-31 09:40:49 -07:00
Leonardo de Moura
6183c7676e
feat(frontends/lean): use . for field access
2017-03-28 15:29:54 -07:00
Leonardo de Moura
092985f777
fix(frontends/lean/util): fixes #1495
...
We should freeze only constants
2017-03-28 11:55:11 -07:00
Sebastian Ullrich
d8eef9e68e
feat(frontends/lean/util): allow lazily resolved auto params
2017-03-27 13:42:08 -07:00
Leonardo de Moura
fdadada3a9
fix(frontends/lean): fixes #1468
...
@kha I had to add yet another hack to fix this issue.
In notation declarations, names are resolved at notation declaration time.
So, users do not expect them to be resolved again at tactic execution time.
I addressed this problem by wrapping constants occurring in notation
declarations with a "frozen_name" annotation. This transformation is
only performed if m_in_quote is true.
Then resolve_names_fn at elaborator.cpp will not try to resolve the
names again.
This change broke two other modules. `-` notation for inverting
equations at `rw`, and `calc` expressions inside quotes.
The broke for the same reason. They were not expecting the constants
to be wrapped with an annotation.
2017-03-18 13:48:21 -07:00
Sebastian Ullrich
e3bfd90b06
fix(frontends/lean/elaborator): default recover_from_error to false for most commands
...
Fixes #1446
fix(frontends/lean/util): quoting private name
uncovered by now failing run test
2017-03-09 20:51:35 -08:00
Leonardo de Moura
23935ee390
feat(frontends/lean): allow auto_param notation in structure declarations
...
See #1422
TODO: take the auto_param into account in the `{ ... }` notation.
2017-03-08 15:41:30 -08:00
Sebastian Ullrich
2394f1faa5
fix(frontends/lean/util): do not fall back to current position
2017-03-06 11:02:51 -08:00
Sebastian Ullrich
dfe1874365
refactor(frontends/lean/{parser,util}): extract quote functions
...
Also fixes ``f when f is private
2017-02-23 01:52:13 +01:00
Leonardo de Moura
c8bbb34e2a
feat(frontends/lean): add auto_param gadget
2017-02-09 15:49:10 -08:00
Leonardo de Moura
32e6442d0a
feat(frontends/lean): no global universes in the frontend
2017-02-08 17:23:04 -08:00
Gabriel Ebner
95068e4e79
feat(library/sorry): make sorry a macro
2017-02-05 14:01:03 +01:00
Leonardo de Moura
01414cf21c
feat(frontends/lean): add token class, and procedure for consuming the tokens
2017-02-03 18:11:06 -08:00
Gabriel Ebner
5fdc737dfc
feat(library/tactic): store name of current declaration in tactic_state
2017-01-28 08:27:19 +01:00
Leonardo de Moura
71a7a7f466
feat(frontends/lean): add default field values
2017-01-22 21:25:49 -08:00
Leonardo de Moura
30cea2dceb
fix(frontends/lean): auxiliary bind-application in do-notation was not allowing us to obtain type information for the monadic actions.
...
The new test exposes the problem.
2017-01-12 18:38:31 -08:00
Leonardo de Moura
7e1db95c79
fix(frontends/lean): doc strings after constants and axioms
2017-01-12 00:22:37 -08:00
Leonardo de Moura
7a150b41b9
fix(frontends/lean): fixes #1292
2017-01-09 15:53:37 -08:00
Sebastian Ullrich
26e2aeec7a
feat(frontends/lean,shell): complete attributes
2017-01-06 14:02:31 -08:00
Sebastian Ullrich
98398b16f3
feat(frontends/lean,shell): implement completing options
2016-12-27 21:41:02 -08:00
Leonardo de Moura
e13bac41c3
fix(frontends/lean): 'sorry' axiom auto generation
2016-12-08 10:31:52 -08:00
Leonardo de Moura
ea3adf4a7c
feat(library/init/meta/tactic): universe polymorphic tactics
2016-10-25 03:42:55 +08:00
Leonardo de Moura
9b84db083d
fix(frontends/lean): error localization bugs
2016-10-15 13:40:57 -07:00
Leonardo de Moura
d0d75c0923
refactor(kernel): reduce number of configurations supported in the kernel
...
Now, eta and impredicativity are assumed to be always true.
Motivation: the rest of the system assumes eta.
Regarding impredicativity, we decided to support only the standard library.
2016-09-27 17:07:01 -07:00
Leonardo de Moura
bbf21b4e65
feat(frontends/lean/begin_end_block): auto-quote identifiers
2016-09-25 17:25:21 -07:00
Leonardo de Moura
6d9a9b46f3
chore(frontends/lean): cleanup
2016-09-23 16:26:21 -07:00
Leonardo de Moura
2a069a4d2a
chore(frontends/lean): remove server and info_manager
2016-09-19 18:44:03 -07:00