Leonardo de Moura
e252446432
doc: cite "Generalizing Monads to Arrows"
...
cc @Kha
2020-06-01 08:02:32 -07:00
Sebastian Ullrich
c81f4605e3
doc: Parser.lean
2020-06-01 07:53:09 -07:00
Sebastian Ullrich
6614b4d6e3
fix: use exact instead of prefix token match when inheriting precedence
...
/cc @leodemoura :)
2020-05-28 14:14:52 +02:00
Leonardo de Moura
5dffa0093a
feat: retrieve implicit lbp from Environment at syntax command
...
@Kha It is not clear to me why I had to change the following line
```
-syntax term ">>>" term : foo
+syntax term:1 ">>>":1 term : foo
```
The test breaks without it.
2020-05-27 17:11:57 -07:00
Leonardo de Moura
bbdf1f39ed
chore: update stage0
2020-05-27 16:15:19 -07:00
Leonardo de Moura
dbe4aa447e
chore: explicit lbp at ParserDescr.symbol
2020-05-27 16:12:53 -07:00
Leonardo de Moura
6e5cd5fcc0
chore: change coercion from String to Parser
...
@Kha
I kept `TokenInfo` as is. That is, the `lbp` field is still `Option Nat`.
I changed my mind because we have the combinator `NonReservedSymbol`.
It feels weird to have a combinator that does not create a keyword,
but sets the `lbp`. Recall that it is used at `Lean/Parser/Tactic.lean`.
Other observations:
- We use symbols in auxiliary constructions (e.g., `mkAntiquot`). It
feels weird to set their `lbp` there.
- It felt weird to specify the `lbp` in places such as
```
def structCtor := parser! ident >> optional inferMod >> symbol " :: " 67
```
- We have a few parsing rules where the same symbol appears twice.
It is funny to set the `lbp` twice. Note that the approach we
discussed yesterday (retrieving the `lbp` from the `Environment`)
would not work here.
2020-05-27 15:59:12 -07:00
Leonardo de Moura
e51ed38bd0
chore: update stage0
2020-05-27 14:15:00 -07:00
Sebastian Ullrich
7a664863fd
fix: leanmake: allow users to add custom LEAN_PATH
2020-05-27 19:46:35 +02:00
Sebastian Ullrich
7e13952510
feat: simplify LEAN_PATH
2020-05-27 19:46:16 +02:00
Sebastian Ullrich
8227eea87b
chore: simplify stdlib.make.in
2020-05-27 19:42:44 +02:00
Leonardo de Moura
50fc961037
chore: update stage0
2020-05-26 15:05:01 -07:00
Leonardo de Moura
862795e9e9
fix: usesLeanAPI
2020-05-26 15:05:01 -07:00
Leonardo de Moura
17b6957f6c
chore: fix tests
2020-05-26 15:05:01 -07:00
Leonardo de Moura
f820341430
chore: update stage0
2020-05-26 15:05:01 -07:00
Leonardo de Moura
cef80c707b
fix: missing deps
2020-05-26 15:05:01 -07:00
Leonardo de Moura
9c0bd9dd41
chore: fix tests
2020-05-26 15:05:00 -07:00
Leonardo de Moura
cd3d72190c
chore: update stage0
2020-05-26 15:05:00 -07:00
Leonardo de Moura
4ccc3fef52
chore: move Init.Lean files to Lean package
2020-05-26 15:04:35 -07:00
Leonardo de Moura
b0dbaada54
chore: update stage0
2020-05-26 13:56:49 -07:00
Leonardo de Moura
4bca76a87e
chore: use src/Lean.lean to initialize lean
2020-05-26 13:54:13 -07:00
Leonardo de Moura
49fc82c604
chore: add Lean package to leanc.in
2020-05-26 13:51:06 -07:00
Leonardo de Moura
f7818757ef
chore: add Lean package to CMakeLists.txt
2020-05-26 13:50:04 -07:00
Leonardo de Moura
834286113f
feat: add Lean package to builtin path
2020-05-26 13:43:19 -07:00
Leonardo de Moura
c765bd2a7e
chore: update stage0
2020-05-26 13:39:48 -07:00
Leonardo de Moura
8d30f67823
feat: add Lean package
2020-05-26 13:39:03 -07:00
Sebastian Ullrich
c11e88c768
test: Reparen: don't remove parentheses in syntax quotations
2020-05-26 14:32:42 +02:00
Sebastian Ullrich
d25a4b311a
fix: missing precedence
2020-05-26 14:32:42 +02:00
Sebastian Ullrich
674fea4876
fix: parenthesizer: adjust lbp after parenthesization
2020-05-26 14:32:42 +02:00
Sebastian Ullrich
e6d27c276b
feat: #eval: capture stderr
2020-05-26 14:32:42 +02:00
Sebastian Ullrich
b519997b58
feat: parenthesizer: handle choice
2020-05-26 14:32:42 +02:00
Sebastian Ullrich
1cbe54fa44
fix: parenthesizer: backtracking special case
2020-05-26 14:32:42 +02:00
Sebastian Ullrich
60ac03916e
feat: introduce anonymous antiquotations for all categories
2020-05-26 14:32:42 +02:00
Sebastian Ullrich
48246c8e4a
feat: parenthesizer: support antiquotations
2020-05-26 11:47:38 +02:00
Sebastian Ullrich
b35b973a5d
fix: precedence of ! in old frontend
2020-05-26 11:26:57 +02:00
Sebastian Ullrich
a884ea8656
feat: ToExpr (Option _)
2020-05-26 11:26:57 +02:00
Sebastian Ullrich
185b02a435
feat: parenthesize tactics
2020-05-26 11:26:57 +02:00
Sebastian Ullrich
95d03a123d
fix: sepBy parenthesizer
2020-05-26 11:26:57 +02:00
Sebastian Ullrich
9247911e09
fix: basic parenthesizer approach, document
2020-05-26 11:26:57 +02:00
Sebastian Ullrich
3431d934de
fix: initSearchPath: use valid default value
2020-05-26 11:26:57 +02:00
Sebastian Ullrich
52b9bb35ea
test: reparenthesize files
2020-05-26 11:26:57 +02:00
Sebastian Ullrich
b37953611a
feat: parenthesizer: missing parsers
2020-05-26 11:26:57 +02:00
Sebastian Ullrich
2313990c87
feat: Syntax.formatStx: optionally show all source info
2020-05-26 11:26:57 +02:00
Sebastian Ullrich
a8a92d8e8c
feat: parenthesizer: preserve whitespace
2020-05-26 11:26:57 +02:00
Sebastian Ullrich
e83edefcc1
fix: Syntax.setHeadInfo
2020-05-26 11:26:57 +02:00
Sebastian Ullrich
ed326491ab
fix: missing token precedence
2020-05-26 11:26:57 +02:00
Sebastian Ullrich
3caf6e83f8
feat: IO.runMeta: print traces (by default)
2020-05-26 11:26:57 +02:00
Leonardo de Moura
e10507e661
chore: update stage0
2020-05-23 16:53:53 -07:00
Sebastian Ullrich
c50cd2527c
fix: include headers in test
2020-05-23 12:39:49 +02:00
Sebastian Ullrich
47bb2a59a8
fix: fail build if building Init failed
2020-05-23 12:39:14 +02:00