| Index: pkg/compiler/lib/src/types/union_type_mask.dart
|
| diff --git a/pkg/compiler/lib/src/types/union_type_mask.dart b/pkg/compiler/lib/src/types/union_type_mask.dart
|
| index 8ba9a6ad3fb02ce450f74c40f1dd51f9e116f6fe..0aa45362c46f175386c999c3a599cd9df25b0939 100644
|
| --- a/pkg/compiler/lib/src/types/union_type_mask.dart
|
| +++ b/pkg/compiler/lib/src/types/union_type_mask.dart
|
| @@ -88,6 +88,8 @@ class UnionTypeMask implements TypeMask {
|
| }
|
|
|
| static TypeMask flatten(List<FlatTypeMask> masks, ClosedWorld closedWorld) {
|
| + // TODO(johnniwinther): Move this computation to [ClosedWorld] and use the
|
| + // class set structures.
|
| assert(masks.length > 1);
|
| // If either type mask is a subtype type mask, we cannot use a
|
| // subclass type mask to represent their union.
|
| @@ -104,7 +106,7 @@ class UnionTypeMask implements TypeMask {
|
| for (Entity candidate in candidates) {
|
| bool isInstantiatedStrictSubclass(cls) =>
|
| cls != candidate &&
|
| - closedWorld.isDirectlyInstantiated(cls) &&
|
| + closedWorld.isRootInstantiated(cls) &&
|
| closedWorld.isSubclassOf(cls, candidate);
|
|
|
| int size;
|
|
|