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

Unified Diff: pkg/compiler/lib/src/tree/unparser.dart

Issue 1069983005: Model 'await for' as an explicit node in tree and fix its handling. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: fix failing assertion rebase Created 5 years, 8 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 | « pkg/compiler/lib/src/tree/prettyprint.dart ('k') | pkg/compiler/lib/src/typechecker.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/tree/unparser.dart
diff --git a/pkg/compiler/lib/src/tree/unparser.dart b/pkg/compiler/lib/src/tree/unparser.dart
index d7dbda7c7dc0efec321c9ea53465961b8fc414d3..5325f1377dff6fb58b8bffa528a3487fa034cdca 100644
--- a/pkg/compiler/lib/src/tree/unparser.dart
+++ b/pkg/compiler/lib/src/tree/unparser.dart
@@ -623,11 +623,23 @@ class Unparser extends Indentation implements Visitor {
visitGotoStatement(node);
}
- visitForIn(ForIn node) {
- if (node.awaitToken != null) {
- write(node.awaitToken.value);
- write(' ');
- }
+ visitAsyncForIn(AsyncForIn node) {
+ write(node.awaitToken.value);
+ write(' ');
+ write(node.forToken.value);
+ space();
+ write('(');
+ visit(node.declaredIdentifier);
+ write(' ');
+ addToken(node.inToken);
+ visit(node.expression);
+ write(')');
+ space();
+ visit(node.body);
+ }
+
+
+ visitSyncForIn(SyncForIn node) {
write(node.forToken.value);
space();
write('(');
« no previous file with comments | « pkg/compiler/lib/src/tree/prettyprint.dart ('k') | pkg/compiler/lib/src/typechecker.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698