Index: pkg/compiler/lib/src/cps_ir/redundant_phi.dart |
diff --git a/pkg/compiler/lib/src/cps_ir/redundant_phi.dart b/pkg/compiler/lib/src/cps_ir/redundant_phi.dart |
index 11c6bf088639f5cec3a10c03f617c2b38ce994ac..dbf3686c8e69ead9bd3175358b39254a602e91bc 100644 |
--- a/pkg/compiler/lib/src/cps_ir/redundant_phi.dart |
+++ b/pkg/compiler/lib/src/cps_ir/redundant_phi.dart |
@@ -15,8 +15,18 @@ part of dart2js.optimizers; |
class RedundantPhiEliminator extends RecursiveVisitor implements Pass { |
final Set<Continuation> workSet = new Set<Continuation>(); |
- void rewrite(final FunctionDefinition root) { |
+ void rewrite(final ExecutableDefinition root) => root.acceptPass(this); |
+ |
+ void rewriteFunctionDefinition(final FunctionDefinition root) { |
if (root.isAbstract) return; |
+ rewriteExecutableDefinition(root); |
+ } |
+ |
+ void rewriteFieldDefinition(final FieldDefinition root) { |
+ rewriteExecutableDefinition(root); |
+ } |
+ |
+ void rewriteExecutableDefinition(final ExecutableDefinition root) { |
// Set all parent pointers. |
new _ParentVisitor().visit(root); |