| 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 6f8c81367584a09ac669ef49f8e5eebfb414dc86..61663499171b5bfdd9a94c4b7541b9a857f1bfd4 100644
|
| --- a/pkg/compiler/lib/src/types/union_type_mask.dart
|
| +++ b/pkg/compiler/lib/src/types/union_type_mask.dart
|
| @@ -118,11 +118,11 @@ class UnionTypeMask implements TypeMask {
|
| // TODO(sigmund, johnniwinther): computing length here (and below) is
|
| // expensive. If we can't prevent `flatten` from being called a lot, it
|
| // might be worth caching results.
|
| - size = classWorld.strictSubclassesOf(candidate).length;
|
| - assert(size <= classWorld.strictSubtypesOf(candidate).length);
|
| + size = classWorld.strictSubclassCount(candidate);
|
| + assert(size <= classWorld.strictSubtypeCount(candidate));
|
| } else {
|
| kind = FlatTypeMask.SUBTYPE;
|
| - size = classWorld.strictSubtypesOf(candidate).length;
|
| + size = classWorld.strictSubtypeCount(candidate);
|
| }
|
| // Update the best candidate if the new one is better.
|
| if (bestElement == null || size < bestSize) {
|
|
|