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

Unified Diff: pkg/compiler/lib/src/tree_ir/tree_ir_tracer.dart

Issue 1291333002: Revert "dart2js cps: Compile some loops as 'for' loops." (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 4 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_ir/tree_ir_nodes.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/tree_ir/tree_ir_tracer.dart
diff --git a/pkg/compiler/lib/src/tree_ir/tree_ir_tracer.dart b/pkg/compiler/lib/src/tree_ir/tree_ir_tracer.dart
index 86a24b63116c21a657acfeda6af24f5997fa98de..d82377a63ba7c085ed9625a37717f2606d235b97 100644
--- a/pkg/compiler/lib/src/tree_ir/tree_ir_tracer.dart
+++ b/pkg/compiler/lib/src/tree_ir/tree_ir_tracer.dart
@@ -127,7 +127,7 @@ class BlockCollector extends StatementVisitor {
visitStatement(node.body);
}
- visitFor(For node) {
+ visitWhileCondition(WhileCondition node) {
Block whileBlock = new Block();
_addGotoStatement(whileBlock);
@@ -297,13 +297,11 @@ class TreeTracer extends TracerUtil with StatementVisitor {
printStatement(null, "while true do");
}
- visitFor(For node) {
+ visitWhileCondition(WhileCondition node) {
String bodyTarget = collector.substatements[node.body].name;
String nextTarget = collector.substatements[node.next].name;
- String updates = node.updates.map(expr).join(', ');
printStatement(null, "while ${expr(node.condition)}");
printStatement(null, "do $bodyTarget");
- printStatement(null, "updates ($updates)");
printStatement(null, "then $nextTarget" );
}
« no previous file with comments | « pkg/compiler/lib/src/tree_ir/tree_ir_nodes.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698