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

Unified Diff: src/i18n.js

Issue 1384443002: [es6] Fix missing bits for full @@toPrimitive support. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Remove useless cctest. 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
Index: src/i18n.js
diff --git a/src/i18n.js b/src/i18n.js
index a3e2e34988e11f5cefab337f6d217414adcbe836..d05da3ef993c540b0febcd60f2fa61a8468e3e0f 100644
--- a/src/i18n.js
+++ b/src/i18n.js
@@ -54,7 +54,6 @@ utils.Import(function(from) {
StringSplit = from.StringSplit;
StringSubstr = from.StringSubstr;
StringSubstring = from.StringSubstring;
- ToNumber = from.ToNumber;
});
// -------------------------------------------------------------------
@@ -1278,7 +1277,7 @@ function initializeNumberFormat(numberFormat, locales, options) {
*/
function formatNumber(formatter, value) {
// Spec treats -0 and +0 as 0.
- var number = ToNumber(value) + 0;
+ var number = TO_NUMBER(value) + 0;
return %InternalNumberFormat(%GetImplFromInitializedIntlObject(formatter),
number);
@@ -1703,7 +1702,7 @@ function formatDate(formatter, dateValue) {
if (IS_UNDEFINED(dateValue)) {
dateMs = %DateCurrentTime();
} else {
- dateMs = ToNumber(dateValue);
+ dateMs = TO_NUMBER(dateValue);
}
if (!IsFinite(dateMs)) throw MakeRangeError(kDateRange);
« no previous file with comments | « src/hydrogen.cc ('k') | src/json.js » ('j') | test/cctest/compiler/test-run-jscalls.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698