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

Unified Diff: src/date.js

Issue 990883002: Hide Math function implementations in a closure. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: remove printf and unnecessary test case change. Created 5 years, 9 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 | « src/arraybuffer.js ('k') | src/harmony-string.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/date.js
diff --git a/src/date.js b/src/date.js
index 208a5b2b4bec27f45ccc7aef9d4836a10c8bdacc..ff24e9cc19af5e0037f45c1ee29c4f7a484d1188 100644
--- a/src/date.js
+++ b/src/date.js
@@ -230,8 +230,8 @@ function LocalTimezoneString(date) {
var timezoneOffset = -TIMEZONE_OFFSET(date);
var sign = (timezoneOffset >= 0) ? 1 : -1;
- var hours = FLOOR((sign * timezoneOffset)/60);
- var min = FLOOR((sign * timezoneOffset)%60);
+ var hours = $floor((sign * timezoneOffset)/60);
+ var min = $floor((sign * timezoneOffset)%60);
var gmt = ' GMT' + ((sign == 1) ? '+' : '-') +
TwoDigitString(hours) + TwoDigitString(min);
return gmt + ' (' + timezone + ')';
@@ -684,7 +684,7 @@ function DateToGMTString() {
function PadInt(n, digits) {
if (digits == 1) return n;
- return n < MathPow(10, digits - 1) ? '0' + PadInt(n, digits - 1) : n;
+ return n < %_MathPow(10, digits - 1) ? '0' + PadInt(n, digits - 1) : n;
}
« no previous file with comments | « src/arraybuffer.js ('k') | src/harmony-string.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698