| Index: dart/sdk/lib/_internal/compiler/implementation/closure.dart
|
| diff --git a/dart/sdk/lib/_internal/compiler/implementation/closure.dart b/dart/sdk/lib/_internal/compiler/implementation/closure.dart
|
| index a10ccbdf821b2f4ac4e77bcc5aae835ec7b7405d..b0061d90dbc3690e801f991b81337856ab7690ee 100644
|
| --- a/dart/sdk/lib/_internal/compiler/implementation/closure.dart
|
| +++ b/dart/sdk/lib/_internal/compiler/implementation/closure.dart
|
| @@ -18,7 +18,6 @@ class ClosureNamer {
|
| }
|
| }
|
|
|
| -
|
| class ClosureTask extends CompilerTask {
|
| Map<Node, ClosureClassMap> closureMappingCache;
|
| ClosureNamer namer;
|
| @@ -68,12 +67,26 @@ class ClosureTask extends CompilerTask {
|
| // TODO(ahe): These classes continuously cause problems. We need to
|
| // move these classes to elements/modelx.dart or see if we can find a
|
| // more general solution.
|
| -class ClosureFieldElement extends ElementX {
|
| +class ClosureFieldElement extends ElementX implements VariableElement {
|
| + /// The source variable this element refers to.
|
| + final Element variableElement;
|
| +
|
| ClosureFieldElement(SourceString name,
|
| this.variableElement,
|
| ClassElement enclosing)
|
| : super(name, ElementKind.FIELD, enclosing);
|
|
|
| + VariableListElement get variables {
|
| + throw new SpannableAssertionFailure(
|
| + variableElement, 'Should not access variables of ClosureFieldElement.');
|
| + }
|
| +
|
| + Expression get cachedNode {
|
| + throw new SpannableAssertionFailure(
|
| + variableElement,
|
| + 'Should not access cachedNode of ClosureFieldElement.');
|
| + }
|
| +
|
| bool isInstanceMember() => true;
|
| bool isAssignable() => false;
|
| // The names of closure variables don't need renaming, since their use is very
|
| @@ -86,11 +99,6 @@ class ClosureFieldElement extends ElementX {
|
| }
|
|
|
| String toString() => "ClosureFieldElement($name)";
|
| -
|
| - /**
|
| - * The source variable this element refers to.
|
| - */
|
| - final Element variableElement;
|
| }
|
|
|
| // TODO(ahe): These classes continuously cause problems. We need to
|
|
|