Index: pkg/compiler/lib/src/ssa/types.dart |
diff --git a/pkg/compiler/lib/src/ssa/types.dart b/pkg/compiler/lib/src/ssa/types.dart |
index 9ebbc552ae4aece8bb82bfbaf856baa38f01aa01..29cc9ab598c43fcc9710f78e1eab0ea0d5c1452c 100644 |
--- a/pkg/compiler/lib/src/ssa/types.dart |
+++ b/pkg/compiler/lib/src/ssa/types.dart |
@@ -4,6 +4,7 @@ |
import '../common_elements.dart' show CommonElements; |
import '../elements/elements.dart'; |
+import '../elements/entities.dart'; |
import '../native/native.dart' as native; |
import '../types/types.dart'; |
import '../universe/selector.dart' show Selector; |
@@ -17,7 +18,11 @@ class TypeMaskFactory { |
} |
static TypeMask inferredTypeForMember( |
- MemberElement element, GlobalTypeInferenceResults results) { |
+ MemberEntity element, GlobalTypeInferenceResults results) { |
+ // TODO(johnniwinther): Support inferred types for member entities. |
+ if (element is! MemberElement) { |
+ return results.closedWorld.commonMasks.dynamicType; |
+ } |
return results.resultOfMember(element).type ?? |
results.closedWorld.commonMasks.dynamicType; |
} |