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

Unified Diff: pkg/compiler/lib/src/tree_ir/optimization/statement_rewriter.dart

Issue 1222673002: dart2js cps: Fix bug in assignment propagation. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 6 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 | 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/optimization/statement_rewriter.dart
diff --git a/pkg/compiler/lib/src/tree_ir/optimization/statement_rewriter.dart b/pkg/compiler/lib/src/tree_ir/optimization/statement_rewriter.dart
index 382d9e9bb63d89f884f1315609efcc00d9f61915..67a40b772a4e6c0676e9de2b012e8bc869ee05af 100644
--- a/pkg/compiler/lib/src/tree_ir/optimization/statement_rewriter.dart
+++ b/pkg/compiler/lib/src/tree_ir/optimization/statement_rewriter.dart
@@ -379,6 +379,7 @@ class StatementRewriter extends Transformer implements Pass {
popDominatingAssignment(leftHand);
if (assign.variable.readCount > 0) {
// The assignment could not be propagated.
+ constantEnvironment.remove(assign.variable);
asgerf 2015/07/02 14:55:01 This matters for variables that have a single use
floitsch 2015/07/02 16:01:24 Can you put this as a comment?
asgerf 2015/07/02 16:09:45 Done.
assign.value = visitExpression(assign.value);
stmt.next = next;
return stmt;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698