diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2019-07-20 10:00:35 +0100 |
---|---|---|
committer | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2019-07-20 10:00:35 +0100 |
commit | 2830d1376b05794c7bf1467fe52ad3bc0eb4ca41 (patch) | |
tree | 7a717bb2a51489b4e1bc50895bff45f1e217f15c /crates/ra_parser/src/syntax_kind | |
parent | e18f8495d6569f4fc0b7457b65a1d199cf7b5974 (diff) | |
parent | 3a7f07c62d3dd253d63c483ee291d9471f539479 (diff) |
Merge #1558
1558: Support .await syntax r=matklad a=unrealhoang
- [x] Add `await` keyword to grammar, parser for await_expr
- [ ] Infer type for await_expr
Co-authored-by: Unreal Hoang <[email protected]>
Diffstat (limited to 'crates/ra_parser/src/syntax_kind')
-rw-r--r-- | crates/ra_parser/src/syntax_kind/generated.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/crates/ra_parser/src/syntax_kind/generated.rs b/crates/ra_parser/src/syntax_kind/generated.rs index 374fd5aec..4b5abb516 100644 --- a/crates/ra_parser/src/syntax_kind/generated.rs +++ b/crates/ra_parser/src/syntax_kind/generated.rs | |||
@@ -105,6 +105,7 @@ pub enum SyntaxKind { | |||
105 | RETURN_KW, | 105 | RETURN_KW, |
106 | TRY_KW, | 106 | TRY_KW, |
107 | BOX_KW, | 107 | BOX_KW, |
108 | AWAIT_KW, | ||
108 | AUTO_KW, | 109 | AUTO_KW, |
109 | DEFAULT_KW, | 110 | DEFAULT_KW, |
110 | EXISTENTIAL_KW, | 111 | EXISTENTIAL_KW, |
@@ -193,6 +194,7 @@ pub enum SyntaxKind { | |||
193 | INDEX_EXPR, | 194 | INDEX_EXPR, |
194 | METHOD_CALL_EXPR, | 195 | METHOD_CALL_EXPR, |
195 | FIELD_EXPR, | 196 | FIELD_EXPR, |
197 | AWAIT_EXPR, | ||
196 | TRY_EXPR, | 198 | TRY_EXPR, |
197 | CAST_EXPR, | 199 | CAST_EXPR, |
198 | REF_EXPR, | 200 | REF_EXPR, |
@@ -338,6 +340,7 @@ macro_rules! T { | |||
338 | (return) => { $crate::SyntaxKind::RETURN_KW }; | 340 | (return) => { $crate::SyntaxKind::RETURN_KW }; |
339 | (try) => { $crate::SyntaxKind::TRY_KW }; | 341 | (try) => { $crate::SyntaxKind::TRY_KW }; |
340 | (box) => { $crate::SyntaxKind::BOX_KW }; | 342 | (box) => { $crate::SyntaxKind::BOX_KW }; |
343 | (await) => { $crate::SyntaxKind::AWAIT_KW }; | ||
341 | (auto) => { $crate::SyntaxKind::AUTO_KW }; | 344 | (auto) => { $crate::SyntaxKind::AUTO_KW }; |
342 | (default) => { $crate::SyntaxKind::DEFAULT_KW }; | 345 | (default) => { $crate::SyntaxKind::DEFAULT_KW }; |
343 | (existential) => { $crate::SyntaxKind::EXISTENTIAL_KW }; | 346 | (existential) => { $crate::SyntaxKind::EXISTENTIAL_KW }; |
@@ -398,6 +401,7 @@ impl SyntaxKind { | |||
398 | | RETURN_KW | 401 | | RETURN_KW |
399 | | TRY_KW | 402 | | TRY_KW |
400 | | BOX_KW | 403 | | BOX_KW |
404 | | AWAIT_KW | ||
401 | | AUTO_KW | 405 | | AUTO_KW |
402 | | DEFAULT_KW | 406 | | DEFAULT_KW |
403 | | EXISTENTIAL_KW | 407 | | EXISTENTIAL_KW |
@@ -572,6 +576,7 @@ impl SyntaxKind { | |||
572 | RETURN_KW => &SyntaxInfo { name: "RETURN_KW" }, | 576 | RETURN_KW => &SyntaxInfo { name: "RETURN_KW" }, |
573 | TRY_KW => &SyntaxInfo { name: "TRY_KW" }, | 577 | TRY_KW => &SyntaxInfo { name: "TRY_KW" }, |
574 | BOX_KW => &SyntaxInfo { name: "BOX_KW" }, | 578 | BOX_KW => &SyntaxInfo { name: "BOX_KW" }, |
579 | AWAIT_KW => &SyntaxInfo { name: "AWAIT_KW" }, | ||
575 | AUTO_KW => &SyntaxInfo { name: "AUTO_KW" }, | 580 | AUTO_KW => &SyntaxInfo { name: "AUTO_KW" }, |
576 | DEFAULT_KW => &SyntaxInfo { name: "DEFAULT_KW" }, | 581 | DEFAULT_KW => &SyntaxInfo { name: "DEFAULT_KW" }, |
577 | EXISTENTIAL_KW => &SyntaxInfo { name: "EXISTENTIAL_KW" }, | 582 | EXISTENTIAL_KW => &SyntaxInfo { name: "EXISTENTIAL_KW" }, |
@@ -660,6 +665,7 @@ impl SyntaxKind { | |||
660 | INDEX_EXPR => &SyntaxInfo { name: "INDEX_EXPR" }, | 665 | INDEX_EXPR => &SyntaxInfo { name: "INDEX_EXPR" }, |
661 | METHOD_CALL_EXPR => &SyntaxInfo { name: "METHOD_CALL_EXPR" }, | 666 | METHOD_CALL_EXPR => &SyntaxInfo { name: "METHOD_CALL_EXPR" }, |
662 | FIELD_EXPR => &SyntaxInfo { name: "FIELD_EXPR" }, | 667 | FIELD_EXPR => &SyntaxInfo { name: "FIELD_EXPR" }, |
668 | AWAIT_EXPR => &SyntaxInfo { name: "AWAIT_EXPR" }, | ||
663 | TRY_EXPR => &SyntaxInfo { name: "TRY_EXPR" }, | 669 | TRY_EXPR => &SyntaxInfo { name: "TRY_EXPR" }, |
664 | CAST_EXPR => &SyntaxInfo { name: "CAST_EXPR" }, | 670 | CAST_EXPR => &SyntaxInfo { name: "CAST_EXPR" }, |
665 | REF_EXPR => &SyntaxInfo { name: "REF_EXPR" }, | 671 | REF_EXPR => &SyntaxInfo { name: "REF_EXPR" }, |
@@ -752,6 +758,7 @@ impl SyntaxKind { | |||
752 | "return" => RETURN_KW, | 758 | "return" => RETURN_KW, |
753 | "try" => TRY_KW, | 759 | "try" => TRY_KW, |
754 | "box" => BOX_KW, | 760 | "box" => BOX_KW, |
761 | "await" => AWAIT_KW, | ||
755 | _ => return None, | 762 | _ => return None, |
756 | }; | 763 | }; |
757 | Some(kw) | 764 | Some(kw) |