Index: src/runtime/runtime-array.cc |
diff --git a/src/runtime/runtime-array.cc b/src/runtime/runtime-array.cc |
index 6484e4d2957be630a2cda0f27789027e7fe88a47..6b27e19f0e3a38b8e201f90a0e2a11a185e710a2 100644 |
--- a/src/runtime/runtime-array.cc |
+++ b/src/runtime/runtime-array.cc |
@@ -22,8 +22,9 @@ RUNTIME_FUNCTION(Runtime_FinishArrayPrototypeSetup) { |
DCHECK(args.length() == 1); |
CONVERT_ARG_HANDLE_CHECKED(JSArray, prototype, 0); |
Object* length = prototype->length(); |
- RUNTIME_ASSERT(length->IsSmi() && Smi::cast(length)->value() == 0); |
- RUNTIME_ASSERT(prototype->HasFastSmiOrObjectElements()); |
+ CHECK(length->IsSmi()); |
+ CHECK(Smi::cast(length)->value() == 0); |
+ CHECK(prototype->HasFastSmiOrObjectElements()); |
// This is necessary to enable fast checks for absence of elements |
// on Array.prototype and below. |
prototype->set_elements(isolate->heap()->empty_fixed_array()); |
@@ -85,7 +86,7 @@ RUNTIME_FUNCTION(Runtime_FixedArraySet) { |
RUNTIME_FUNCTION(Runtime_TransitionElementsKind) { |
HandleScope scope(isolate); |
- RUNTIME_ASSERT(args.length() == 2); |
+ DCHECK(args.length() == 2); |
CONVERT_ARG_HANDLE_CHECKED(JSArray, array, 0); |
CONVERT_ARG_HANDLE_CHECKED(Map, map, 1); |
JSObject::TransitionElementsKind(array, map->elements_kind()); |
@@ -193,8 +194,8 @@ RUNTIME_FUNCTION(Runtime_GetArrayKeys) { |
} |
if (!array->elements()->IsDictionary()) { |
- RUNTIME_ASSERT(array->HasFastSmiOrObjectElements() || |
- array->HasFastDoubleElements()); |
+ CHECK(array->HasFastSmiOrObjectElements() || |
+ array->HasFastDoubleElements()); |
uint32_t actual_length = static_cast<uint32_t>(array->elements()->length()); |
return *isolate->factory()->NewNumberFromUint(Min(actual_length, length)); |
} |
@@ -409,8 +410,8 @@ RUNTIME_FUNCTION(Runtime_NormalizeElements) { |
HandleScope scope(isolate); |
DCHECK(args.length() == 1); |
CONVERT_ARG_HANDLE_CHECKED(JSObject, array, 0); |
- RUNTIME_ASSERT(!array->HasFixedTypedArrayElements() && |
- !array->IsJSGlobalProxy()); |
+ CHECK(!array->HasFixedTypedArrayElements()); |
+ CHECK(!array->IsJSGlobalProxy()); |
JSObject::NormalizeElements(array); |
return *array; |
} |