DJMcNab
4899e7be76
Support universal function call syntax in function calls
2019-01-24 21:19:16 +00:00
Josh Robson Chase
2ffea72f74
More correct raw ident handling
2019-01-23 13:57:17 -05:00
Josh Robson Chase
3b70acad01
Use IDENT for both raw and normal idents
2019-01-23 13:19:49 -05:00
Josh Robson Chase
1cd6d6539a
Add raw idents to lexer and parser
2019-01-23 13:17:41 -05:00
Erlend Tobiassen
c550c6759d
Add test for placeholder parameters in trait fn defs
2019-01-22 18:46:15 +01:00
Erlend Tobiassen
8198cde13b
Update tests after allowing where predicate to accept types
2019-01-22 14:32:23 +01:00
Marcus Klaas de Vries
fa43ef30f4
Change parsing of struct field patterns
2019-01-19 15:37:26 +03:00
Marcus Klaas de Vries
bcbfa2cc11
Finish move of StructField for pattern type inference
2019-01-19 15:37:26 +03:00
DJMcNab
0b9e462ab0
Fix handling of attributes in positional field lists
2019-01-12 15:42:12 +00:00
DJMcNab
afdb569902
Fix handling of where clauses in tuple structs
2019-01-10 18:21:01 +00:00
Aleksey Kladov
d91a98ec84
switch ra_syntax to new rowan API
2019-01-08 11:20:15 +03:00
Florian Diebold
bb029cd29b
Rename traits::impl_item -> impl_block as well, as well as the tests
2019-01-04 19:15:15 +01:00
Florian Diebold
fe6c4115f6
Rename ImplItem to ImplBlock
...
rustc uses the name ImplItem for items in impls, not the impl {} block itself,
which could lead to confusion.
2019-01-04 18:28:36 +01:00
csmoe
8a6d6ac132
add mod doc comment test
2019-01-04 21:28:09 +08:00
DJMcNab
0ddeb3b824
Fix the same bug as #396 but for bytes too
2019-01-01 12:10:21 +00:00
DJMcNab
72ab6f7727
Fix the panic
found whilst fuzzing
2018-12-31 23:02:04 +00:00
bors[bot]
c0d1b17a4e
Merge #366
...
366: parse minus before number literal pattern r=matklad a=csmoe
r?@matklad
![unknown](https://user-images.githubusercontent.com/35686186/50547871-d5449e00-0c7d-11e9-9ff5-1031e78019de.png )
Co-authored-by: csmoe <csmoe@msn.com>
2018-12-30 16:40:16 +00:00
csmoe
53c94e3ad8
parse minus before number literal
2018-12-30 23:25:07 +08:00
DJMcNab
b67a4e7a57
Add fuzz failure to the fuzz-failures directory
2018-12-29 12:45:48 +00:00
Aleksey Kladov
49b0fe20ab
fix suffix ranges
2018-12-27 15:10:30 +03:00
Florian Diebold
0d724ea572
Improve parsing of incomplete field accesses in preparation for field completion
...
We need to be able to get the receiver even if there is no field name yet, and
currently "a." wouldn't get parsed as a field name at all. This seems to help.
2018-12-25 15:16:42 +01:00
Florian Diebold
515c3bc59b
Cleanup
2018-12-23 13:48:04 +01:00
Florian Diebold
7348f7883f
Add testing infrastructure for type inference
...
- move dir_tests to test_utils for that.
2018-12-23 13:48:04 +01:00
DJMcNab
1dffbe5c37
Remove TODO on self_hosting_parsing
...
This improving this code is not a good use of people-time, and this
might be the most performant approach nonwithstanding
an api for this use case being added to walkdir
2018-12-21 22:44:31 +00:00
DJMcNab
bd5a358910
Fix where clauses using fully qualified path syntax
2018-12-21 17:20:38 +00:00
DJMcNab
9beee92500
Add comment about the source of the weird_exprs test
2018-12-21 10:03:02 +00:00
DJMcNab
da6be9fdda
Add weird_exprs test
2018-12-20 19:47:29 +00:00
DJMcNab
a349db7178
Run gen-tests
2018-12-20 19:10:37 +00:00
DJMcNab
134fe4f566
Fix the tests and fix the precommit hook
2018-12-20 16:45:54 +00:00
DJMcNab
63ca8bc91a
Change parser tests dir to inline/ok and inline/err
2018-12-20 15:09:22 +00:00
DJMcNab
e2a7e94518
Ensure that the parser tests pass or fail correctly
2018-12-20 13:33:00 +00:00
DJMcNab
5205c016e9
Fix ambiguity with if break
...
Brought up by #290
2018-12-20 11:35:02 +00:00
DJMcNab
a3b842fb8b
Add tests and only traverse in the crates directory
2018-12-19 21:19:32 +00:00
DJMcNab
db67741430
Move is_block to lower in the call tree
2018-12-19 20:55:24 +00:00
DJMcNab
def0a95d35
Revert "Revert to f6f7c5"
...
This approach is correct, but it needs an addition to Restrictions too
This reverts commit ad00d0c8a5f64142e6636e8b048204c8f8982f4a.
2018-12-19 20:12:18 +00:00
DJMcNab
cd8e33fb7e
Revert to f6f7c5
2018-12-19 20:12:18 +00:00
DJMcNab
7a8560ba38
Fix expression parsing by bailing out upon a macro block being found
...
TODO: Fix this when the block like macro is in expression position
E.g. `test(test!{})` currently parses
2018-12-19 20:12:18 +00:00
DJMcNab
20bbe0127c
Fix parsing of inclusive ranges ( #214 )
...
I'm not certain that this is correct, so extra eyes would be good
2018-12-19 20:12:18 +00:00
DJMcNab
0b77eec922
Add a test to ensure that we can parse each file
...
Note that this has a non-spurious failure in ra_analysis/src/mock_analysis
2018-12-19 20:12:18 +00:00
Roland Ruckerbauer
d0f1334226
Fixed cast expression parsing in ra_syntax.
...
The cast expression expected any type via types::type_() function,
but the language spec does only allow TypeNoBounds (types without direct extra bounds
via `+`).
**Example:**
```rust
fn test() {
6i8 as i32 + 5;
}
```
This fails, because the types::type_() function which should parse the type after the
as keyword is greedy, and takes all plus sign after path types as extra.
My proposed fix is to replace the not implemented `type_no_plus()` just calls (`type_()`)
function, which is used at several places. The replacement is `type_with_bounds_cond(p: &mut Parser, allow_bounds: bool)`, which passes the condition to relevant sub-parsers.
This function is then called by `type_()` and the new public `type_no_bounds()`.
2018-12-17 17:26:24 +01:00
Bernardo
0527e3b283
rename Edit to TextEdit and AtomEdit to AtomTextEdit
2018-12-11 19:07:17 +01:00
DJMcNab
455ef940fe
Update use path test
2018-12-05 22:08:00 +00:00
DJMcNab
0a82d768c4
Improve/add the use_item documentation
2018-12-05 21:43:40 +00:00
Aleksey Kladov
2ed1514df3
rename ROOT -> SOURCE_FILE
2018-11-07 18:42:36 +03:00
Aleksey Kladov
f8b36bbc3b
Rename File -> SourceFileNode
2018-11-07 18:42:36 +03:00
Aleksey Kladov
ec131b6c7b
grammar: fix where clause parsing
...
closes #205
2018-11-06 21:19:32 +03:00
Aleksey Kladov
9010cb9839
grammar: for predicates in where
...
closes #191
2018-11-05 11:24:08 +03:00
Jeremy A. Kolb
61f3a438d3
Cargo Format
...
Run `cargo fmt` and ignore generated files
2018-10-16 09:41:10 -04:00
Aleksey Kladov
376639c70f
Parse crate paths in expressions
2018-10-15 20:52:56 +03:00
Aleksey Kladov
a05e09e9c5
Attach comments smartly
2018-10-08 17:36:38 +03:00