Chromium Code Reviews| Index: pkg/analyzer/lib/src/generated/testing/test_type_provider.dart |
| diff --git a/pkg/analyzer/lib/src/generated/testing/test_type_provider.dart b/pkg/analyzer/lib/src/generated/testing/test_type_provider.dart |
| index 5b5204a3d752f8acde2fc57558a13ab4179b9f3c..85cc8902810d68551e58b4cb2ad1dec7a83c7d22 100644 |
| --- a/pkg/analyzer/lib/src/generated/testing/test_type_provider.dart |
| +++ b/pkg/analyzer/lib/src/generated/testing/test_type_provider.dart |
| @@ -208,7 +208,10 @@ class TestTypeProvider implements TypeProvider { |
| @override |
| InterfaceType get functionType { |
| if (_functionType == null) { |
| - _functionType = ElementFactory.classElement2("Function").type; |
| + ClassElementImpl functionClassElement = |
| + ElementFactory.classElement2("Function"); |
| + _functionType = functionClassElement.type; |
| + functionClassElement.constructors = <ConstructorElement>[]; |
|
Brian Wilkerson
2015/11/11 15:26:10
I'm surprised that this is necessary. I thought we
Paul Berry
2015/11/11 19:12:22
What we currently do is: in the constructor for Cl
|
| } |
| return _functionType; |
| } |
| @@ -396,7 +399,10 @@ class TestTypeProvider implements TypeProvider { |
| @override |
| InterfaceType get stackTraceType { |
| if (_stackTraceType == null) { |
| - _stackTraceType = ElementFactory.classElement2("StackTrace").type; |
| + ClassElementImpl stackTraceClassElement = |
| + ElementFactory.classElement2("StackTrace"); |
| + _stackTraceType = stackTraceClassElement.type; |
| + stackTraceClassElement.constructors = <ConstructorElement>[]; |
| } |
| return _stackTraceType; |
| } |
| @@ -463,7 +469,9 @@ class TestTypeProvider implements TypeProvider { |
| @override |
| InterfaceType get typeType { |
| if (_typeType == null) { |
| - _typeType = ElementFactory.classElement2("Type").type; |
| + ClassElementImpl typeClassElement = ElementFactory.classElement2("Type"); |
| + _typeType = typeClassElement.type; |
| + typeClassElement.constructors = <ConstructorElement>[]; |
| } |
| return _typeType; |
| } |