diff options
author | bors[bot] <bors[bot]@users.noreply.github.com> | 2019-01-24 22:02:23 +0000 |
---|---|---|
committer | bors[bot] <bors[bot]@users.noreply.github.com> | 2019-01-24 22:02:23 +0000 |
commit | b308375b82a33687f93468d75c7cc628b83a1351 (patch) | |
tree | 8675aee76ac940e4916a2b2d0cbb6e075bb17967 /crates/ra_syntax/src/grammar/expressions/atom.rs | |
parent | abb9bfe44dfe1fb0685ead5e000ed281c55c8968 (diff) | |
parent | 107d6a0a16c8dc89394b9ee69ec3b20f52a5a721 (diff) |
Merge #631
631: Support universal function call syntax in function calls r=matklad a=DJMcNab
Fix #596
Co-authored-by: DJMcNab <[email protected]>
Co-authored-by: Daniel McNab <[email protected]>
Diffstat (limited to 'crates/ra_syntax/src/grammar/expressions/atom.rs')
-rw-r--r-- | crates/ra_syntax/src/grammar/expressions/atom.rs | 36 |
1 files changed, 16 insertions, 20 deletions
diff --git a/crates/ra_syntax/src/grammar/expressions/atom.rs b/crates/ra_syntax/src/grammar/expressions/atom.rs index 167a76551..6d6d89f70 100644 --- a/crates/ra_syntax/src/grammar/expressions/atom.rs +++ b/crates/ra_syntax/src/grammar/expressions/atom.rs | |||
@@ -36,26 +36,22 @@ pub(crate) fn literal(p: &mut Parser) -> Option<CompletedMarker> { | |||
36 | } | 36 | } |
37 | 37 | ||
38 | // E.g. for after the break in `if break {}`, this should not match | 38 | // E.g. for after the break in `if break {}`, this should not match |
39 | pub(super) const ATOM_EXPR_FIRST: TokenSet = LITERAL_FIRST.union(token_set![ | 39 | pub(super) const ATOM_EXPR_FIRST: TokenSet = |
40 | L_PAREN, | 40 | LITERAL_FIRST.union(paths::PATH_FIRST).union(token_set![ |
41 | L_CURLY, | 41 | L_PAREN, |
42 | L_BRACK, | 42 | L_CURLY, |
43 | PIPE, | 43 | L_BRACK, |
44 | MOVE_KW, | 44 | PIPE, |
45 | IF_KW, | 45 | MOVE_KW, |
46 | WHILE_KW, | 46 | IF_KW, |
47 | MATCH_KW, | 47 | WHILE_KW, |
48 | UNSAFE_KW, | 48 | MATCH_KW, |
49 | RETURN_KW, | 49 | UNSAFE_KW, |
50 | IDENT, | 50 | RETURN_KW, |
51 | SELF_KW, | 51 | BREAK_KW, |
52 | SUPER_KW, | 52 | CONTINUE_KW, |
53 | CRATE_KW, | 53 | LIFETIME, |
54 | COLONCOLON, | 54 | ]); |
55 | BREAK_KW, | ||
56 | CONTINUE_KW, | ||
57 | LIFETIME, | ||
58 | ]); | ||
59 | 55 | ||
60 | const EXPR_RECOVERY_SET: TokenSet = token_set![LET_KW]; | 56 | const EXPR_RECOVERY_SET: TokenSet = token_set![LET_KW]; |
61 | 57 | ||