| Index: sdk/lib/_internal/compiler/implementation/resolution/scope.dart
|
| diff --git a/sdk/lib/_internal/compiler/implementation/resolution/scope.dart b/sdk/lib/_internal/compiler/implementation/resolution/scope.dart
|
| index 0af9fd78b325db9e25abd819366a322b2e4fb601..81eadaebbfd52814cf78aa4811fd73e8ee023b46 100644
|
| --- a/sdk/lib/_internal/compiler/implementation/resolution/scope.dart
|
| +++ b/sdk/lib/_internal/compiler/implementation/resolution/scope.dart
|
| @@ -41,6 +41,24 @@ abstract class NestedScope extends Scope {
|
| }
|
| }
|
|
|
| +class VariableDefinitionScope extends NestedScope {
|
| + final SourceString variableName;
|
| + bool variableReferencedInInitializer = false;
|
| +
|
| + VariableDefinitionScope(Scope parent, this.variableName) : super(parent);
|
| +
|
| + Element localLookup(SourceString name) {
|
| + if (name == variableName) {
|
| + variableReferencedInInitializer = true;
|
| + }
|
| + return null;
|
| + }
|
| +
|
| + Element add(Element newElement) {
|
| + throw "Cannot add element to VariableDefinitionScope";
|
| + }
|
| +}
|
| +
|
| /**
|
| * [TypeDeclarationScope] defines the outer scope of a type declaration in
|
| * which the declared type variables and the entities in the enclosing scope are
|
|
|