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, |