Index: lib/compiler/implementation/closure.dart |
=================================================================== |
--- lib/compiler/implementation/closure.dart (revision 14321) |
+++ lib/compiler/implementation/closure.dart (working copy) |
@@ -45,9 +45,7 @@ |
return measure(() { |
ClosureClassMap nestedClosureData = closureMappingCache[node]; |
if (nestedClosureData == null) { |
- // TODO(floitsch): we can only assume that the reason for not having a |
- // closure data here is, because the function is inside an initializer. |
- compiler.unimplemented("Closures inside initializers", node: node); |
+ compiler.internalError("No closure cache", node: node); |
} |
return nestedClosureData; |
}); |
@@ -610,9 +608,8 @@ |
// TODO(ahe): This is problematic. The backend should not repeat |
// the work of the resolver. It is the resolver's job to create |
// parameters, etc. Other phases should only visit statements. |
- // TODO(floitsch): we avoid visiting the initializers on purpose so that |
- // we get an error-message later in the builder. |
if (node.parameters != null) node.parameters.accept(this); |
+ if (node.initializers != null) node.initializers.accept(this); |
if (node.body != null) node.body.accept(this); |
}); |
} |