Commit f5839996 authored by lrn@chromium.org's avatar lrn@chromium.org

More cases of CallFunction that doesn't work correctly.

Review URL: http://codereview.chromium.org/6603015

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@7044 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 30c0420b
......@@ -1138,7 +1138,7 @@ function ArrayReduce(callback, current) {
for (; i < length; i++) {
var element = this[i];
if (!IS_UNDEFINED(element) || i in this) {
current = %_CallFunction(null, current, element, i, this, callback);
current = callback.call(null, current, element, i, this);
}
}
return current;
......@@ -1164,7 +1164,7 @@ function ArrayReduceRight(callback, current) {
for (; i >= 0; i--) {
var element = this[i];
if (!IS_UNDEFINED(element) || i in this) {
current = %_CallFunction(null, current, element, i, this, callback);
current = callback.call(null, current, element, i, this);
}
}
return current;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment