Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(587)

Unified Diff: pkg/analyzer/lib/src/fasta/ast_builder.dart

Issue 2769133004: Parse YieldStatement with Fasta. (Closed)
Patch Set: Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | pkg/analyzer/test/generated/parser_fasta_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/src/fasta/ast_builder.dart
diff --git a/pkg/analyzer/lib/src/fasta/ast_builder.dart b/pkg/analyzer/lib/src/fasta/ast_builder.dart
index 63d3b1e9d28c38efc5e9ee4deb2dcbb6d4cb478b..67fca00847cf2a4dc05190eefa78833e15a60f26 100644
--- a/pkg/analyzer/lib/src/fasta/ast_builder.dart
+++ b/pkg/analyzer/lib/src/fasta/ast_builder.dart
@@ -439,6 +439,15 @@ class AstBuilder extends ScopeListener {
}
@override
+ void endYieldStatement(Token yieldToken, Token starToken, Token endToken) {
+ debugEvent("YieldStatement");
+ assert(endToken.lexeme == ';');
+ Expression expression = pop();
+ push(ast.yieldStatement(toAnalyzerToken(yieldToken),
+ toAnalyzerToken(starToken), expression, toAnalyzerToken(endToken)));
+ }
+
+ @override
void handleNoVariableInitializer(Token token) {
debugEvent("NoVariableInitializer");
}
« no previous file with comments | « no previous file | pkg/analyzer/test/generated/parser_fasta_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698