Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(528)

Unified Diff: pkg/compiler/lib/src/types/forwarding_type_mask.dart

Issue 1755823003: Replace TypeMask.isEmpty by isEmptyOrNull, use isEmpty when it's really empty. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/compiler/lib/src/types/flat_type_mask.dart ('k') | pkg/compiler/lib/src/types/map_type_mask.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/types/forwarding_type_mask.dart
diff --git a/pkg/compiler/lib/src/types/forwarding_type_mask.dart b/pkg/compiler/lib/src/types/forwarding_type_mask.dart
index a4400c616ad6a2af51069b7415fa89358fde34d2..6212bb8b1a321c1bae44b36ab44729441271241d 100644
--- a/pkg/compiler/lib/src/types/forwarding_type_mask.dart
+++ b/pkg/compiler/lib/src/types/forwarding_type_mask.dart
@@ -14,8 +14,10 @@ abstract class ForwardingTypeMask implements TypeMask {
ForwardingTypeMask();
+ bool get isEmptyOrNull => forwardTo.isEmptyOrNull;
bool get isEmpty => forwardTo.isEmpty;
bool get isNullable => forwardTo.isNullable;
+ bool get isNull => forwardTo.isNull;
bool get isExact => forwardTo.isExact;
bool get isUnion => false;
@@ -78,7 +80,7 @@ abstract class ForwardingTypeMask implements TypeMask {
return this;
} else if (equalsDisregardNull(other)) {
return other.isNullable ? other : this;
- } else if (other.isEmpty) {
+ } else if (other.isEmptyOrNull) {
return other.isNullable ? this.nullable() : this;
}
return forwardTo.union(other, classWorld);
« no previous file with comments | « pkg/compiler/lib/src/types/flat_type_mask.dart ('k') | pkg/compiler/lib/src/types/map_type_mask.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698