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

Unified Diff: src/array.js

Issue 7044054: Fix Array.prototype.{reduce,reduceRight} to pass undefined as receiver (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Address comments Created 9 years, 6 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 | « no previous file | src/parser.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/array.js
diff --git a/src/array.js b/src/array.js
index 6cf417874da2924caf1477be658cefb408bfc3bc..34ebd4e227fc5fdc23656b38091d8dbe4f9b52cc 100644
--- a/src/array.js
+++ b/src/array.js
@@ -1252,7 +1252,7 @@ function ArrayReduce(callback, current) {
for (; i < length; i++) {
var element = this[i];
if (!IS_UNDEFINED(element) || i in this) {
- current = callback.call(null, current, element, i, this);
+ current = callback.call(void 0, current, element, i, this);
}
}
return current;
@@ -1283,7 +1283,7 @@ function ArrayReduceRight(callback, current) {
for (; i >= 0; i--) {
var element = this[i];
if (!IS_UNDEFINED(element) || i in this) {
- current = callback.call(null, current, element, i, this);
+ current = callback.call(void 0, current, element, i, this);
}
}
return current;
« no previous file with comments | « no previous file | src/parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698