Chromium Code Reviews| Index: src/bootstrapper.cc |
| diff --git a/src/bootstrapper.cc b/src/bootstrapper.cc |
| index 63ad9abf663d32834030d6164fb002dff1df16a6..67f8ae241ed5f8e337877ff3eb1ae778f72e8d5b 100644 |
| --- a/src/bootstrapper.cc |
| +++ b/src/bootstrapper.cc |
| @@ -4343,28 +4343,40 @@ bool Genesis::InstallNatives(GlobalContextType context_type) { |
| // Install Array.prototype.forEach |
| Handle<JSFunction> forEach = InstallArrayBuiltinFunction( |
| - proto, "forEach", Builtins::kArrayForEach, 2); |
| + proto, "forEach", Builtins::kArrayForEach, |
| + SharedFunctionInfo::kDontAdaptArgumentsSentinel); |
|
Igor Sheludko
2017/04/27 10:38:05
Idea for further improvement: it would be nice to
danno
2017/04/28 06:58:10
As discussed, I'll do this in a later CL.
|
| // Add forEach to the context. |
| native_context()->set_array_for_each_iterator(*forEach); |
| // Install Array.prototype.filter |
| - InstallArrayBuiltinFunction(proto, "filter", Builtins::kArrayFilter, 2); |
| + InstallArrayBuiltinFunction( |
| + proto, "filter", Builtins::kArrayFilter, |
| + SharedFunctionInfo::kDontAdaptArgumentsSentinel); |
| // Install Array.prototype.map |
| - InstallArrayBuiltinFunction(proto, "map", Builtins::kArrayMap, 2); |
| + InstallArrayBuiltinFunction( |
| + proto, "map", Builtins::kArrayMap, |
| + SharedFunctionInfo::kDontAdaptArgumentsSentinel); |
| // Install Array.prototype.every |
| - InstallArrayBuiltinFunction(proto, "every", Builtins::kArrayEvery, 2); |
| + InstallArrayBuiltinFunction( |
| + proto, "every", Builtins::kArrayEvery, |
| + SharedFunctionInfo::kDontAdaptArgumentsSentinel); |
| // Install Array.prototype.some |
| - InstallArrayBuiltinFunction(proto, "some", Builtins::kArraySome, 2); |
| + InstallArrayBuiltinFunction( |
| + proto, "some", Builtins::kArraySome, |
| + SharedFunctionInfo::kDontAdaptArgumentsSentinel); |
| // Install Array.prototype.reduce |
| - InstallArrayBuiltinFunction(proto, "reduce", Builtins::kArrayReduce, 2); |
| + InstallArrayBuiltinFunction( |
| + proto, "reduce", Builtins::kArrayReduce, |
| + SharedFunctionInfo::kDontAdaptArgumentsSentinel); |
| // Install Array.prototype.reduceRight |
| - InstallArrayBuiltinFunction(proto, "reduceRight", |
| - Builtins::kArrayReduceRight, 2); |
| + InstallArrayBuiltinFunction( |
| + proto, "reduceRight", Builtins::kArrayReduceRight, |
| + SharedFunctionInfo::kDontAdaptArgumentsSentinel); |
| } |
| // Install InternalArray.prototype.concat |