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

Unified Diff: lib/runtime/dart/collection.js

Issue 1348453004: fix some errors in our SDK, mostly around numbers (Closed) Base URL: git@github.com:dart-lang/dev_compiler.git@master
Patch Set: Created 5 years, 3 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 | « lib/runtime/dart/_native_typed_data.js ('k') | lib/runtime/dart/convert.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: lib/runtime/dart/collection.js
diff --git a/lib/runtime/dart/collection.js b/lib/runtime/dart/collection.js
index c24f062251c865225c9bda8cb7bd42319f5c0f76..b8549f75c8127651964e7eb8faf149f6af4ddd40 100644
--- a/lib/runtime/dart/collection.js
+++ b/lib/runtime/dart/collection.js
@@ -4371,7 +4371,7 @@ dart_library.library('dart/collection', null, /* Imports */[
return typeof key == 'string' && !dart.equals(key, '__proto__');
}
static _isNumericKey(key) {
- return dart.is(key, core.num) && (key & 0x3ffffff) === key;
+ return typeof key == 'number' && (key & 0x3ffffff) === key;
}
[_computeHashCode](key) {
return dart.hashCode(key) & 0x3ffffff;
@@ -4858,7 +4858,7 @@ dart_library.library('dart/collection', null, /* Imports */[
return typeof key == 'string' && !dart.equals(key, '__proto__');
}
static _isNumericKey(key) {
- return dart.is(key, core.num) && (key & 0x3ffffff) === key;
+ return typeof key == 'number' && (key & 0x3ffffff) === key;
}
[_computeHashCode](key) {
return dart.hashCode(key) & 0x3ffffff;
@@ -5303,7 +5303,7 @@ dart_library.library('dart/collection', null, /* Imports */[
return typeof element == 'string' && !dart.equals(element, '__proto__');
}
static _isNumericElement(element) {
- return dart.is(element, core.num) && (element & 0x3ffffff) === element;
+ return typeof element == 'number' && (element & 0x3ffffff) === element;
}
[_computeHashCode](element) {
return dart.hashCode(element) & 0x3ffffff;
@@ -5739,7 +5739,7 @@ dart_library.library('dart/collection', null, /* Imports */[
return typeof element == 'string' && !dart.equals(element, '__proto__');
}
static _isNumericElement(element) {
- return dart.is(element, core.num) && (element & 0x3ffffff) === element;
+ return typeof element == 'number' && (element & 0x3ffffff) === element;
}
[_computeHashCode](element) {
return dart.hashCode(element) & 0x3ffffff;
« no previous file with comments | « lib/runtime/dart/_native_typed_data.js ('k') | lib/runtime/dart/convert.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698