Template literal arrays should not be marked. (#4352)
Make array object big endian compatible. JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg zherczeg.u-szeged@partner.samsung.com
This commit is contained in:
@@ -114,7 +114,6 @@ parser_new_tagged_template_literal (ecma_object_t **raw_strings_p) /**< [out] ra
|
||||
ecma_get_magic_string (LIT_MAGIC_STRING_RAW),
|
||||
ecma_make_object_value (*raw_strings_p),
|
||||
ECMA_PROPERTY_FIXED);
|
||||
ecma_deref_object (*raw_strings_p);
|
||||
|
||||
return template_obj_p;
|
||||
} /* parser_new_tagged_template_literal */
|
||||
@@ -129,8 +128,8 @@ parser_tagged_template_literal_freeze_array (ecma_object_t *obj_p)
|
||||
|
||||
ecma_op_ordinary_object_prevent_extensions (obj_p);
|
||||
ecma_extended_object_t *ext_obj_p = (ecma_extended_object_t *) obj_p;
|
||||
uint8_t new_prop_value = (uint8_t) (ext_obj_p->u.array.u.length_prop & ~ECMA_PROPERTY_FLAG_WRITABLE);
|
||||
ext_obj_p->u.array.u.length_prop = new_prop_value;
|
||||
ext_obj_p->u.array.length_prop_and_hole_count &= (uint32_t) ~ECMA_PROPERTY_FLAG_WRITABLE;
|
||||
ext_obj_p->u.array.length_prop_and_hole_count |= ECMA_ARRAY_TEMPLATE_LITERAL;
|
||||
} /* parser_tagged_template_literal_freeze_array */
|
||||
|
||||
/**
|
||||
|
||||
@@ -2732,8 +2732,9 @@ parser_raise_error (parser_context_t *context_p, /**< context */
|
||||
#if ENABLED (JERRY_ESNEXT)
|
||||
if (saved_context_p->tagged_template_literal_cp != JMEM_CP_NULL)
|
||||
{
|
||||
ecma_collection_free (ECMA_GET_INTERNAL_VALUE_POINTER (ecma_collection_t,
|
||||
saved_context_p->tagged_template_literal_cp));
|
||||
ecma_collection_t *collection = ECMA_GET_INTERNAL_VALUE_POINTER (ecma_collection_t,
|
||||
saved_context_p->tagged_template_literal_cp);
|
||||
ecma_collection_free_template_literal (collection);
|
||||
}
|
||||
#endif /* ENABLED (JERRY_ESNEXT) */
|
||||
|
||||
@@ -2743,8 +2744,9 @@ parser_raise_error (parser_context_t *context_p, /**< context */
|
||||
#if ENABLED (JERRY_ESNEXT)
|
||||
if (context_p->tagged_template_literal_cp != JMEM_CP_NULL)
|
||||
{
|
||||
ecma_collection_free (ECMA_GET_INTERNAL_VALUE_POINTER (ecma_collection_t,
|
||||
context_p->tagged_template_literal_cp));
|
||||
ecma_collection_t *collection = ECMA_GET_INTERNAL_VALUE_POINTER (ecma_collection_t,
|
||||
context_p->tagged_template_literal_cp);
|
||||
ecma_collection_free_template_literal (collection);
|
||||
}
|
||||
#endif /* ENABLED (JERRY_ESNEXT) */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user