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

Unified Diff: lib/compiler/implementation/ssa/optimize.dart

Issue 10122005: Fix some type warnings. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 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 | « lib/compiler/implementation/ssa/nodes.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/compiler/implementation/ssa/optimize.dart
diff --git a/lib/compiler/implementation/ssa/optimize.dart b/lib/compiler/implementation/ssa/optimize.dart
index 81d405b11475b73898fb64d7a89e3147fc29bb62..2c630487bd9091f9d2d82fd49101838c28d03548 100644
--- a/lib/compiler/implementation/ssa/optimize.dart
+++ b/lib/compiler/implementation/ssa/optimize.dart
@@ -154,13 +154,16 @@ class SsaConstantFolder extends HBaseVisitor implements OptimizationPhase {
if (node.isLengthGetter()) {
HInstruction input = node.inputs[1];
if (input.isConstantString()) {
- StringConstant constant = input.constant;
+ HConstant constantInput = input;
+ StringConstant constant = constantInput.constant;
return graph.addConstantInt(constant.length);
} else if (input.isConstantList()) {
- ListConstant constant = input.constant;
+ HConstant constantInput = input;
+ ListConstant constant = constantInput.constant;
return graph.addConstantInt(constant.length);
} else if (input.isConstantMap()) {
- MapConstant constant = input.constant;
+ HConstant constantInput = input;
+ MapConstant constant = constantInput.constant;
return graph.addConstantInt(constant.length);
}
}
« no previous file with comments | « lib/compiler/implementation/ssa/nodes.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698