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

Unified Diff: pkg/compiler/lib/src/ssa/builder.dart

Issue 1077093002: Revert "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: 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/scanner/listener.dart ('k') | pkg/compiler/lib/src/ssa/nodes.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/ssa/builder.dart
diff --git a/pkg/compiler/lib/src/ssa/builder.dart b/pkg/compiler/lib/src/ssa/builder.dart
index 189b9b8a2c93165a7551d03299da7d4dbf071b50..195b1889b24fde56b7a157ad1c86cce0e7428ea6 100644
--- a/pkg/compiler/lib/src/ssa/builder.dart
+++ b/pkg/compiler/lib/src/ssa/builder.dart
@@ -5424,7 +5424,8 @@ class SsaBuilder extends NewResolvedVisitor {
return new JumpHandler(this, element);
}
- visitAsyncForIn(ast.AsyncForIn node) {
+ buildAsyncForIn(ast.ForIn node) {
+ assert(node.isAsync);
// The async-for is implemented with a StreamIterator.
HInstruction streamIterator;
@@ -5490,7 +5491,11 @@ class SsaBuilder extends NewResolvedVisitor {
});
}
- visitSyncForIn(ast.SyncForIn node) {
+ visitForIn(ast.ForIn node) {
+ if (node.isAsync) {
+ return buildAsyncForIn(node);
+ }
+
// Generate a structure equivalent to:
// Iterator<E> $iter = <iterable>.iterator;
// while ($iter.moveNext()) {
« no previous file with comments | « pkg/compiler/lib/src/scanner/listener.dart ('k') | pkg/compiler/lib/src/ssa/nodes.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698