| Index: pkg/analyzer/lib/src/dart/element/element.dart
|
| diff --git a/pkg/analyzer/lib/src/dart/element/element.dart b/pkg/analyzer/lib/src/dart/element/element.dart
|
| index afe5715ba97dadc724b53fe9e668859bc36933f0..94571086976362e5e5a202d3b79a7e60505a3b45 100644
|
| --- a/pkg/analyzer/lib/src/dart/element/element.dart
|
| +++ b/pkg/analyzer/lib/src/dart/element/element.dart
|
| @@ -49,12 +49,6 @@ abstract class AbstractClassElementImpl extends ElementImpl
|
| List<FieldElement> _fields;
|
|
|
| /**
|
| - * The type defined by the class.
|
| - */
|
| - @override
|
| - InterfaceType type;
|
| -
|
| - /**
|
| * Initialize a newly created class element to have the given [name] at the
|
| * given [offset] in the file that contains the declaration of this element.
|
| */
|
| @@ -441,6 +435,11 @@ class ClassElementImpl extends AbstractClassElementImpl
|
| InterfaceType _supertype;
|
|
|
| /**
|
| + * The type defined by the class.
|
| + */
|
| + InterfaceType _type;
|
| +
|
| + /**
|
| * A list containing all of the mixins that are applied to the class being
|
| * extended in order to derive the superclass of this class.
|
| */
|
| @@ -877,6 +876,16 @@ class ClassElementImpl extends AbstractClassElementImpl
|
| }
|
|
|
| @override
|
| + InterfaceType get type {
|
| + if (_type == null) {
|
| + InterfaceTypeImpl type = new InterfaceTypeImpl(this);
|
| + type.typeArguments = typeParameterTypes;
|
| + _type = type;
|
| + }
|
| + return _type;
|
| + }
|
| +
|
| + @override
|
| TypeParameterizedElementMixin get typeParameterContext => this;
|
|
|
| @override
|
| @@ -3128,6 +3137,11 @@ class EnumElementImpl extends AbstractClassElementImpl {
|
| final UnlinkedEnum _unlinkedEnum;
|
|
|
| /**
|
| + * The type defined by the enum.
|
| + */
|
| + InterfaceType _type;
|
| +
|
| + /**
|
| * Initialize a newly created class element to have the given [name] at the
|
| * given [offset] in the file that contains the declaration of this element.
|
| */
|
| @@ -3268,6 +3282,16 @@ class EnumElementImpl extends AbstractClassElementImpl {
|
| InterfaceType get supertype => context.typeProvider.objectType;
|
|
|
| @override
|
| + InterfaceType get type {
|
| + if (_type == null) {
|
| + InterfaceTypeImpl type = new InterfaceTypeImpl(this);
|
| + type.typeArguments = const <DartType>[];
|
| + _type = type;
|
| + }
|
| + return _type;
|
| + }
|
| +
|
| + @override
|
| List<TypeParameterElement> get typeParameters =>
|
| const <TypeParameterElement>[];
|
|
|
|
|