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

Unified Diff: src/builtins.cc

Issue 1302413006: Unify ElementsAccessor Array Builtins (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@2015-08-28_elements_accessor_unshift
Patch Set: Created 5 years, 4 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/elements.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/builtins.cc
diff --git a/src/builtins.cc b/src/builtins.cc
index 5ae9a5e94f5107c35a53861d63ae43b23ab38d46..a84d15015c4e3aa01ea5f7cb2cf780b42ad80249 100644
--- a/src/builtins.cc
+++ b/src/builtins.cc
@@ -371,8 +371,7 @@ BUILTIN(ArrayPush) {
}
DCHECK(!array->map()->is_observed());
ElementsAccessor* accessor = array->GetElementsAccessor();
- int new_length = accessor->Push(array, elms_obj, &args[1], push_size,
- ElementsAccessor::kDirectionReverse);
+ int new_length = accessor->Push(array, elms_obj, &args, push_size);
return Smi::FromInt(new_length);
}
@@ -622,7 +621,7 @@ BUILTIN(ArraySplice) {
}
ElementsAccessor* accessor = array->GetElementsAccessor();
Handle<JSArray> result_array = accessor->Splice(
- array, elms_obj, actual_start, actual_delete_count, args, add_count);
+ array, elms_obj, actual_start, actual_delete_count, &args, add_count);
return *result_array;
}
« no previous file with comments | « no previous file | src/elements.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698