From e50e2719df0cfe1bec359302f6830c765d4f3534 Mon Sep 17 00:00:00 2001 From: Szilagyi Adam Date: Mon, 25 May 2020 18:10:38 +0200 Subject: [PATCH] Get the typedArray's length property properly in Array.prototype.concat (#3791) We should use the "length" property instead of the internal arraybuffer's length JerryScript-DCO-1.0-Signed-off-by: Adam Szilagyi aszilagy@inf.u-szeged.hu --- jerry-core/ecma/operations/ecma-objects.c | 8 -------- tests/test262-es6-excludelist.xml | 2 -- 2 files changed, 10 deletions(-) diff --git a/jerry-core/ecma/operations/ecma-objects.c b/jerry-core/ecma/operations/ecma-objects.c index 7f7e3b5c9..9f5a18d1f 100644 --- a/jerry-core/ecma/operations/ecma-objects.c +++ b/jerry-core/ecma/operations/ecma-objects.c @@ -901,14 +901,6 @@ ecma_op_object_get_length (ecma_object_t *object_p, /**< the object */ return ECMA_VALUE_EMPTY; } -#if ENABLED (JERRY_ES2015_BUILTIN_TYPEDARRAY) - if (ecma_object_is_typedarray (object_p)) - { - *length_p = ecma_typedarray_get_length (object_p); - return ECMA_VALUE_EMPTY; - } -#endif /* ENABLED (JERRY_ES2015_BUILTIN_TYPEDARRAY) */ - ecma_value_t len_value = ecma_op_object_get_by_magic_id (object_p, LIT_MAGIC_STRING_LENGTH); ecma_value_t len_number = ecma_op_to_length (len_value, length_p); ecma_free_value (len_value); diff --git a/tests/test262-es6-excludelist.xml b/tests/test262-es6-excludelist.xml index aeab5a456..055c6ca1b 100644 --- a/tests/test262-es6-excludelist.xml +++ b/tests/test262-es6-excludelist.xml @@ -20,8 +20,6 @@ - -