CreepySkeleton
14eeff42a5
Allow <mut name:E> in patterns
2019-08-21 19:24:15 +03:00
Markus Westerlind
8df24776b1
Save the generated lrgrammar.rs file in the repo
2018-10-21 14:21:59 +02:00
Ayose
2060b3e085
Remove unnecessary entries in .gitignore
2018-06-01 02:13:42 +01:00
Markus Westerlind
b16795d155
chore: Commit Cargo.lock so 1.20 will build against string_cache 0.7.1
2018-04-26 23:49:22 +05:30
Aleksey Kladov
fa596a367a
Correctly anchor regex at the begining
...
^foo|bar is (^foo)|bar, and not ^(foo|bar). Adding parens should
fix it.
closes #358
2018-04-04 12:55:40 +03:00
Markus Westerlind
c9fcd1f644
fix: Use the correct type for !
in macro expanded productions
2018-03-17 12:47:30 +01:00
Ahmed Charles
e5875274f4
Update tests.
2018-01-26 12:07:52 +00:00
Volker Mische
daaad78583
Allow match definition if no custom tokens are defined
...
`extern` is not only used for custom lexers/tokens, but also to define
custom types for `Error` and `Location`. It should be possible to
have custom error types while having `match` dedefinitions as issue #261
shows.
Fixes #261 .
2018-01-24 05:18:21 -05:00
Niko Matsakis
226cb536c8
Merge pull request #279 from vmx/issue-278
...
Return grammar errors first
2018-01-24 04:41:24 -05:00
Niko Matsakis
2e0d114793
add new style error recovery function and adjust tests
...
Also, add some detailed tests covering all the cases for error spans.
2018-01-23 13:14:50 -05:00
Niko Matsakis
3f4ed1e1af
add a test for EOF loop
2018-01-23 12:49:26 -05:00
Niko Matsakis
b62a3fc095
make a test demonstrating the lock-in phenomena
2018-01-23 12:49:26 -05:00
Markus Westerlind
08728df48a
Add a test case for issue #240
2018-01-23 12:49:26 -05:00
Volker Mische
f309406335
Return grammar errors first
...
If some production in the grammar returns an error, give it priority
over built-in errors.
Fixes #278 .
2017-11-23 00:43:31 +01:00
Niko Matsakis
920ee76fec
even in parse table, error out if we hit EOF early
2017-08-29 05:46:22 -04:00
Minijackson
4ecd594e51
Add a test for a nicer pull request!
...
It's true because it rhymes
2017-04-17 14:18:19 +02:00
Niko Matsakis
248c752f62
extend the tutorial to explain lexing vs parsing
2017-04-04 06:24:38 -04:00
Niko Matsakis
5d30989369
ignore match_section.rs
2017-04-03 05:55:57 -04:00
Nathan Lilienthal
5fb5c638bc
Remove and ignore generated files.
2017-03-30 13:11:27 -07:00
Markus Westerlind
b69e679d5b
fix: Don't accidentally cast a reduce action to usize
...
This caused panics in certain error recovery scenarios as a reduce action represented by a negative number would get casted to `usize` which then caused an index out of bounds panic.
The added tests were extracted and minimized from [gluon's grammar](abd06a4f6e/parser/src/grammar.lalrpop
) with the test case below being a minimal reproduction.
Panicking
```
type Test = a ->
```
Valid expression
```
type Test = a -> a
in 1
```
2017-01-28 16:22:37 +01:00
Markus Westerlind
bf7c7901e9
fix: Actually avoid all clones when not using error recovery
2016-11-29 17:54:37 +01:00
Markus Westerlind
137e015f43
Add issue_55.rs to .gitignore
2016-11-22 22:36:10 +01:00
Markus Westerlind
7af013e7bb
Add basic error recovery for parse tables
...
This does not yet recover errors at EOF as EOF handling is a separate
step
2016-11-22 22:36:10 +01:00
Markus Westerlind
b9c9ea33bc
Ignore .rs files generated for tests
2016-11-09 21:14:55 +01:00
Niko Matsakis
940b583dde
ignore generated parser
2015-07-24 22:49:08 -04:00
Niko Matsakis
dd83ec0cea
reorganize lalrpop so that it is a library that can be added to
...
a project via build.rs, give a few examples of this in practice
2015-06-29 22:31:14 -07:00
Niko Matsakis
855e8344f1
Add a new parse tree and plan out a bit more what we want
2015-06-13 07:01:50 -04:00
Niko Matsakis
ce6a58de65
Start playing around with how tokens might be specified
2015-06-12 09:49:37 -04:00