Index: src/json-stringifier.h |
diff --git a/src/json-stringifier.h b/src/json-stringifier.h |
index c93196e0c9f18e440296d76d8f4dc5cbb34d1fc7..7eb6746dfbebb802e1c7c18fb18c389e600bf230 100644 |
--- a/src/json-stringifier.h |
+++ b/src/json-stringifier.h |
@@ -560,6 +560,8 @@ BasicJsonStringifier::Result BasicJsonStringifier::SerializeJSArray( |
break; |
} |
case FAST_DOUBLE_ELEMENTS: { |
+ // Empty array is FixedArray but not FixedDoubleArray. |
+ if (length == 0) break; |
Handle<FixedDoubleArray> elements( |
FixedDoubleArray::cast(object->elements()), isolate_); |
for (uint32_t i = 0; i < length; i++) { |