Index: pkg/analyzer/lib/src/generated/testing/element_factory.dart |
diff --git a/pkg/analyzer/lib/src/generated/testing/element_factory.dart b/pkg/analyzer/lib/src/generated/testing/element_factory.dart |
index ac293e74260cf4b8b77d4117f135a950a7c6dec5..106977c835d033c2079830d223ca0c2775dfa369 100644 |
--- a/pkg/analyzer/lib/src/generated/testing/element_factory.dart |
+++ b/pkg/analyzer/lib/src/generated/testing/element_factory.dart |
@@ -47,16 +47,8 @@ class ElementFactory { |
ClassElementImpl element = new ClassElementImpl(typeName, 0); |
element.constructors = const <ConstructorElement>[]; |
element.supertype = superclassType; |
- InterfaceTypeImpl type = new InterfaceTypeImpl(element); |
- element.type = type; |
if (parameterNames != null) { |
- int count = parameterNames.length; |
- if (count > 0) { |
- element.typeParameters = typeParameters(parameterNames); |
- type.typeArguments = new List<DartType>.from( |
- element.typeParameters.map((p) => p.type), |
- growable: false); |
- } |
+ element.typeParameters = typeParameters(parameterNames); |
} |
return element; |
} |
@@ -140,8 +132,7 @@ class ElementFactory { |
// Build the enum. |
// |
EnumElementImpl enumElement = new EnumElementImpl(enumName, -1); |
- InterfaceTypeImpl enumType = new InterfaceTypeImpl(enumElement); |
- enumElement.type = enumType; |
+ InterfaceTypeImpl enumType = enumElement.type; |
// |
// Populate the fields. |
// |