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

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

Issue 1474713002: dart2js cps: Clean up and avoid processing unreachable code. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Merge Created 5 years, 1 month 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
Index: pkg/compiler/lib/src/tree_ir/optimization/variable_merger.dart
diff --git a/pkg/compiler/lib/src/tree_ir/optimization/variable_merger.dart b/pkg/compiler/lib/src/tree_ir/optimization/variable_merger.dart
index 91a5aac7d4c6367ae7fa746122cf67d44940a986..fb31f026f4dd6de108936c0e274bf34b08ac508a 100644
--- a/pkg/compiler/lib/src/tree_ir/optimization/variable_merger.dart
+++ b/pkg/compiler/lib/src/tree_ir/optimization/variable_merger.dart
@@ -20,11 +20,6 @@ class VariableMerger extends RecursiveVisitor implements Pass {
visitStatement(node.body);
}
- @override
- void visitInnerFunction(FunctionDefinition node) {
- rewriteFunction(node);
- }
-
/// Rewrites the given function.
/// This is called for the outermost function and inner functions.
void rewriteFunction(FunctionDefinition node) {
@@ -112,11 +107,6 @@ class BlockGraphBuilder extends RecursiveVisitor {
visitStatement(node.body);
}
- @override
- void visitInnerFunction(FunctionDefinition node) {
- // Do nothing. Inner functions are traversed in VariableMerger.
- }
-
/// Creates a new block with the current exception handler or [catchBlock]
/// if provided.
Block newBlock({Block catchBlock}) {
@@ -506,11 +496,6 @@ class SubstituteVariables extends RecursiveTransformer {
node.body = visitStatement(node.body);
}
- @override
- void visitInnerFunction(FunctionDefinition node) {
- // Do nothing. Inner functions are traversed in VariableMerger.
- }
-
Expression visitVariableUse(VariableUse node) {
node.variable = replaceRead(node.variable);
return node;
« no previous file with comments | « pkg/compiler/lib/src/tree_ir/optimization/statement_rewriter.dart ('k') | pkg/compiler/lib/src/tree_ir/tree_ir_builder.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698