mirror of
https://github.com/jerryscript-project/jerryscript.git
synced 2025-12-15 16:29:21 +00:00
Construct non-fast array in ecma_op_array_species_create (#3514)
Fixes #3506 JerryScript-DCO-1.0-Signed-off-by: Peter Marki marpeter@inf.u-szeged.hu
This commit is contained in:
parent
0d7b461185
commit
c8ce7d8791
@ -704,7 +704,11 @@ ecma_op_array_species_create (ecma_object_t *original_array_p, /**< The object f
|
||||
|
||||
if (ecma_is_value_undefined (constructor))
|
||||
{
|
||||
return ecma_make_object_value (ecma_op_new_fast_array_object (length));
|
||||
ecma_value_t length_val = ecma_make_uint32_value (length);
|
||||
ecma_value_t new_array = ecma_op_create_array_object (&length_val, 1, true);
|
||||
ecma_free_value (length_val);
|
||||
|
||||
return new_array;
|
||||
}
|
||||
|
||||
if (!ecma_is_constructor (constructor))
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user