| Index: sdk/lib/_internal/compiler/implementation/types/flat_type_mask.dart
|
| diff --git a/sdk/lib/_internal/compiler/implementation/types/flat_type_mask.dart b/sdk/lib/_internal/compiler/implementation/types/flat_type_mask.dart
|
| index 1938dfc58aec14c0abb81a11fa3369f9633a1808..3cf1dbf6e9ef3802c7868e86624e31b78b853e40 100644
|
| --- a/sdk/lib/_internal/compiler/implementation/types/flat_type_mask.dart
|
| +++ b/sdk/lib/_internal/compiler/implementation/types/flat_type_mask.dart
|
| @@ -603,7 +603,12 @@ class FlatTypeMask implements TypeMask {
|
| static bool isSubtypeOf(ClassElement x, ClassElement y, Compiler compiler) {
|
| assert(x.isDeclaration && y.isDeclaration);
|
| Set<ClassElement> subtypes = compiler.world.subtypesOf(y);
|
| - return (subtypes != null) ? subtypes.contains(x) : false;
|
| + if (subtypes != null && subtypes.contains(x)) return true;
|
| + if (y != compiler.functionClass) return false;
|
| + // TODO(johnniwinther): Clean this up (function inheritance).
|
| + Member member =
|
| + x.lookupInterfaceMember(const PublicName(Compiler.CALL_OPERATOR_NAME));
|
| + return member != null && member.isMethod;
|
| }
|
|
|
| static Set<ClassElement> commonContainedClasses(FlatTypeMask x,
|
|
|