Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/syntax/rust.ungram')
| -rw-r--r-- | crates/syntax/rust.ungram | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/crates/syntax/rust.ungram b/crates/syntax/rust.ungram index c98adc3818..e3899b97b0 100644 --- a/crates/syntax/rust.ungram +++ b/crates/syntax/rust.ungram @@ -10,6 +10,7 @@ // Name = -- non-terminal definition // 'ident' -- keyword or punct token (terminal) // '?ident' -- contextual keyword (terminal) +// too) // '#ident' -- generic token (terminal) // '@ident' -- literal token (terminal) // A B -- sequence @@ -430,7 +431,7 @@ TryExpr = Attr* Expr '?' BlockExpr = - Attr* Label? ('try' | 'unsafe' | 'async' | 'const') StmtList + Attr* Label? ('try' | 'unsafe' | ('async' 'move'?) | ('gen' 'move'?) | 'const') StmtList PrefixExpr = Attr* op:('-' | '!' | '*') Expr @@ -490,9 +491,12 @@ FieldExpr = Attr* Expr '.' NameRef ClosureExpr = - Attr* ('for' GenericParamList)? 'const'? 'static'? 'async'? 'move'? ParamList RetType? + Attr* ClosureBinder? 'const'? 'static'? 'async'? 'gen'? 'move'? ParamList RetType? body:Expr +ClosureBinder = + 'for' GenericParamList + IfExpr = Attr* 'if' condition:Expr then_branch:BlockExpr ('else' else_branch:(IfExpr | BlockExpr))? |