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

Unified Diff: src/elements.cc

Issue 206073007: ArraySplice builtin handlified. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressing review notes Created 6 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/builtins.cc ('k') | src/factory.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/elements.cc
diff --git a/src/elements.cc b/src/elements.cc
index 5d3ef1308615ee8bc19e8a1879c2330ce5c0ec26..d122870821c3701e35c4fb2dfce9b9199db02b84 100644
--- a/src/elements.cc
+++ b/src/elements.cc
@@ -797,6 +797,23 @@ class ElementsAccessorBase : public ElementsAccessor {
return NULL;
}
+ // TODO(ishell): Temporary wrapper, remove when CopyElements handlified.
+ Handle<Object> CopyElementsHelper(
+ Handle<JSObject> from_holder,
+ uint32_t from_start,
+ ElementsKind from_kind,
+ Handle<FixedArrayBase> to,
+ uint32_t to_start,
+ int copy_size,
+ Handle<FixedArrayBase> from) {
+ CALL_HEAP_FUNCTION(to->GetIsolate(),
+ CopyElements(
+ from_holder.is_null() ? NULL : *from_holder,
+ from_start, from_kind, *to, to_start, copy_size,
+ from.is_null() ? NULL : *from),
+ Object);
+ }
+
virtual void CopyElements(
Handle<JSObject> from_holder,
uint32_t from_start,
@@ -805,11 +822,10 @@ class ElementsAccessorBase : public ElementsAccessor {
uint32_t to_start,
int copy_size,
Handle<FixedArrayBase> from) {
- CALL_HEAP_FUNCTION_VOID(from_holder->GetIsolate(),
- CopyElements(
- from_holder.is_null() ? NULL : *from_holder,
- from_start, from_kind, *to, to_start, copy_size,
- from.is_null() ? NULL : *from));
+ Handle<Object> result = CopyElementsHelper(
+ from_holder, from_start, from_kind, to, to_start, copy_size, from);
+ ASSERT(!result.is_null());
+ USE(result);
}
MUST_USE_RESULT virtual MaybeObject* CopyElements(JSObject* from_holder,
« no previous file with comments | « src/builtins.cc ('k') | src/factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698