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

Unified Diff: sdk/lib/_internal/js_runtime/lib/js_rti.dart

Issue 2595363002: Support for Null as bottom in dart2js (Closed)
Patch Set: Created 4 years 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 | « sdk/lib/_internal/js_runtime/lib/js_helper.dart ('k') | tests/compiler/dart2js/null_is_bottom_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/_internal/js_runtime/lib/js_rti.dart
diff --git a/sdk/lib/_internal/js_runtime/lib/js_rti.dart b/sdk/lib/_internal/js_runtime/lib/js_rti.dart
index 0ce3e69993d74324f3a1466f1ec964b5bff11188..91254ef2dad1901511974373cb340ff30e9d1793 100644
--- a/sdk/lib/_internal/js_runtime/lib/js_rti.dart
+++ b/sdk/lib/_internal/js_runtime/lib/js_rti.dart
@@ -448,6 +448,7 @@ bool isSubtype(var s, var t) {
if (isIdentical(s, t)) return true;
// If either type is dynamic, [s] is a subtype of [t].
if (s == null || t == null) return true;
+ if (isNullType(s)) return true;
if (isDartFunctionType(t)) {
return isFunctionSubtype(s, t);
}
« no previous file with comments | « sdk/lib/_internal/js_runtime/lib/js_helper.dart ('k') | tests/compiler/dart2js/null_is_bottom_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698