File tree Expand file tree Collapse file tree 2 files changed +22
-12
lines changed Expand file tree Collapse file tree 2 files changed +22
-12
lines changed Original file line number Diff line number Diff line change @@ -86,6 +86,7 @@ module.exports = grammar({
8686 [ $ . lambda_expression , $ . primary_expression ] ,
8787 [ $ . inferred_parameters , $ . primary_expression ] ,
8888 [ $ . argument_list , $ . record_pattern_body ] ,
89+ [ $ . yield_statement , $ . _reserved_identifier ] ,
8990 ] ,
9091
9192 word : $ => $ . identifier ,
@@ -1266,17 +1267,19 @@ module.exports = grammar({
12661267 field ( 'body' , $ . block ) ,
12671268 ) ,
12681269
1269- _reserved_identifier : $ => prec ( - 3 , alias (
1270- choice (
1271- 'open' ,
1272- 'module' ,
1273- 'record' ,
1274- 'with' ,
1275- 'yield' ,
1276- 'sealed' ,
1277- ) ,
1278- $ . identifier ,
1279- ) ) ,
1270+ _reserved_identifier : $ => choice (
1271+ prec ( - 3 , alias (
1272+ choice (
1273+ 'open' ,
1274+ 'module' ,
1275+ 'record' ,
1276+ 'with' ,
1277+ 'sealed' ,
1278+ ) ,
1279+ $ . identifier ,
1280+ ) ) ,
1281+ alias ( 'yield' , $ . identifier ) ,
1282+ ) ,
12801283
12811284 this : _ => 'this' ,
12821285
Original file line number Diff line number Diff line change @@ -1081,6 +1081,7 @@ public class Keywords {
10811081 public void demo() {
10821082 int sealed = 0;
10831083 bool yield = false;
1084+ yield(1, 2);
10841085 }
10851086}
10861087
@@ -1113,7 +1114,13 @@ public class Keywords {
11131114 (type_identifier)
11141115 (variable_declarator
11151116 (identifier)
1116- (false))))))))
1117+ (false)))
1118+ (expression_statement
1119+ (method_invocation
1120+ (identifier)
1121+ (argument_list
1122+ (decimal_integer_literal)
1123+ (decimal_integer_literal)))))))))
11171124
11181125================================================================================
11191126Annontations
You can’t perform that action at this time.
0 commit comments