From 3ee0e8a8a542d284762a9ea4926cba5a3ce61233 Mon Sep 17 00:00:00 2001 From: Ruben Ayrapetyan Date: Mon, 28 Jul 2014 21:21:31 +0400 Subject: [PATCH 1/3] Style fixes regarding 'empty' value: introducing ecma_is_empty_completion_value, reducing usage of the 'empty' value, listing possible usage cases of the 'empty' value in the comment to it's definition. --- src/libcoreint/interpreter.c | 3 +- src/libcoreint/opcodes.c | 12 ++---- src/libecmaobjects/ecma-globals.h | 10 ++++- src/libecmaobjects/ecma-helpers-value.c | 40 ++++++++++++++++-- src/libecmaobjects/ecma-helpers.h | 4 +- src/libecmaoperations/ecma-conversion.c | 55 ++++++++++--------------- src/libecmaoperations/ecma-lex-env.c | 17 ++++---- 7 files changed, 81 insertions(+), 60 deletions(-) diff --git a/src/libcoreint/interpreter.c b/src/libcoreint/interpreter.c index dfc9a8b3b..d3bc21132 100644 --- a/src/libcoreint/interpreter.c +++ b/src/libcoreint/interpreter.c @@ -127,8 +127,7 @@ run_int_from_pos (int start_pos, completion = __opfuncs[curr->op_idx](*curr, &int_data); JERRY_ASSERT( !ecma_is_completion_value_normal( completion) - || ecma_is_completion_value_normal_simple_value(completion, - ECMA_SIMPLE_VALUE_EMPTY) ); + || ecma_is_empty_completion_value( completion) ); } while ( completion.type == ECMA_COMPLETION_TYPE_NORMAL ); if ( completion.type == ECMA_COMPLETION_TYPE_BREAK ) diff --git a/src/libcoreint/opcodes.c b/src/libcoreint/opcodes.c index feedc7fd0..e9161574f 100644 --- a/src/libcoreint/opcodes.c +++ b/src/libcoreint/opcodes.c @@ -912,8 +912,7 @@ opfunc_pre_incr(OPCODE opdata, /**< operation data */ ecma_completion_value_t reg_assignment_res = set_variable_value (int_data, dst_var_idx, new_num_value); - JERRY_ASSERT( ecma_is_completion_value_normal_simple_value (reg_assignment_res, - ECMA_SIMPLE_VALUE_EMPTY) ); + JERRY_ASSERT( ecma_is_empty_completion_value( reg_assignment_res) ); ecma_dealloc_number( new_num_p); @@ -963,8 +962,7 @@ opfunc_pre_decr(OPCODE opdata, /**< operation data */ ecma_completion_value_t reg_assignment_res = set_variable_value (int_data, dst_var_idx, new_num_value); - JERRY_ASSERT( ecma_is_completion_value_normal_simple_value (reg_assignment_res, - ECMA_SIMPLE_VALUE_EMPTY) ); + JERRY_ASSERT( ecma_is_empty_completion_value (reg_assignment_res) ); ecma_dealloc_number( new_num_p); @@ -1014,8 +1012,7 @@ opfunc_post_incr(OPCODE opdata, /**< operation data */ ecma_completion_value_t reg_assignment_res = set_variable_value (int_data, dst_var_idx, old_value.value); - JERRY_ASSERT( ecma_is_completion_value_normal_simple_value (reg_assignment_res, - ECMA_SIMPLE_VALUE_EMPTY) ); + JERRY_ASSERT( ecma_is_empty_completion_value( reg_assignment_res) ); ECMA_FINALIZE(old_num_value); ECMA_FINALIZE(old_value); @@ -1063,8 +1060,7 @@ opfunc_post_decr(OPCODE opdata, /**< operation data */ ecma_completion_value_t reg_assignment_res = set_variable_value (int_data, dst_var_idx, old_value.value); - JERRY_ASSERT( ecma_is_completion_value_normal_simple_value (reg_assignment_res, - ECMA_SIMPLE_VALUE_EMPTY) ); + JERRY_ASSERT( ecma_is_empty_completion_value (reg_assignment_res) ); ECMA_FINALIZE(old_num_value); ECMA_FINALIZE(old_value); diff --git a/src/libecmaobjects/ecma-globals.h b/src/libecmaobjects/ecma-globals.h index b1d98b3c6..c58b3e61d 100644 --- a/src/libecmaobjects/ecma-globals.h +++ b/src/libecmaobjects/ecma-globals.h @@ -63,12 +63,18 @@ typedef enum { * Simple ecma-values */ typedef enum { - ECMA_SIMPLE_VALUE_EMPTY, /**< empty value (see also: ECMA-262 v5, 8.9 Completion specification type) */ + /** + * Empty value is implementation defined value, used for: + * - representing empty value in completion values (see also: ECMA-262 v5, 8.9 Completion specification type); + * - values of uninitialized immutable bindings; + * - values of empty register variables. + */ + ECMA_SIMPLE_VALUE_EMPTY, ECMA_SIMPLE_VALUE_UNDEFINED, /**< undefined value */ ECMA_SIMPLE_VALUE_NULL, /**< null value */ ECMA_SIMPLE_VALUE_FALSE, /**< boolean false */ ECMA_SIMPLE_VALUE_TRUE, /**< boolean true */ - ECMA_SIMPLE_VALUE_ARRAY_REDIRECT, /**< special value for an array's elements that exists, + ECMA_SIMPLE_VALUE_ARRAY_REDIRECT, /**< implementation defined value for an array's elements that exists, but is stored directly in the array's property list (used for array elements with non-default attribute values) */ ECMA_SIMPLE_VALUE__COUNT /** count of simple ecma-values */ diff --git a/src/libecmaobjects/ecma-helpers-value.c b/src/libecmaobjects/ecma-helpers-value.c index efa0a1155..f02e1a7a0 100644 --- a/src/libecmaobjects/ecma-helpers-value.c +++ b/src/libecmaobjects/ecma-helpers-value.c @@ -282,6 +282,24 @@ ecma_make_completion_value(ecma_completion_type_t type, /**< type */ return (ecma_completion_value_t) { .type = type, .value = value, .target = target }; } /* ecma_make_completion_value */ +/** + * Simple normal completion value constructor + * + * @return completion value + */ +ecma_completion_value_t +ecma_make_simple_completion_value( ecma_simple_value_t simple_value) /**< simple ecma-value */ +{ + JERRY_ASSERT( simple_value == ECMA_SIMPLE_VALUE_UNDEFINED + || simple_value == ECMA_SIMPLE_VALUE_NULL + || simple_value == ECMA_SIMPLE_VALUE_FALSE + || simple_value == ECMA_SIMPLE_VALUE_TRUE ); + + return ecma_make_completion_value( ECMA_COMPLETION_TYPE_NORMAL, + ecma_make_simple_value( simple_value), + ECMA_TARGET_ID_RESERVED); +} /* ecma_make_simple_completion_value */ + /** * Throw completion value constructor. * @@ -308,8 +326,8 @@ ecma_completion_value_t ecma_make_empty_completion_value( void) { return ecma_make_completion_value( ECMA_COMPLETION_TYPE_NORMAL, - ecma_make_simple_value( ECMA_SIMPLE_VALUE_EMPTY), - ECMA_TARGET_ID_RESERVED); + ecma_make_simple_value( ECMA_SIMPLE_VALUE_EMPTY), + ECMA_TARGET_ID_RESERVED); } /* ecma_make_empty_completion_value */ /** @@ -321,8 +339,8 @@ ecma_completion_value_t ecma_copy_completion_value( ecma_completion_value_t value) /**< completion value */ { return ecma_make_completion_value( value.type, - ecma_copy_value( value.value), - value.target); + ecma_copy_value( value.value), + value.target); } /* ecma_copy_completion_value */ /** @@ -412,6 +430,20 @@ ecma_is_completion_value_normal_false( ecma_completion_value_t value) /**< compl return ecma_is_completion_value_normal_simple_value( value, ECMA_SIMPLE_VALUE_FALSE); } /* ecma_is_completion_value_normal_false */ +/** + * Check if the completion value is normal empty value. + * + * @return true - if the completion type is normal and + * value contains empty simple value, + * false - otherwise. + */ +bool +ecma_is_empty_completion_value( ecma_completion_value_t value) /**< completion value */ +{ + return ( ecma_is_completion_value_normal( value) + && ecma_is_value_empty( value.value) ); +} /* ecma_is_empty_completion_value */ + /** * @} * @} diff --git a/src/libecmaobjects/ecma-helpers.h b/src/libecmaobjects/ecma-helpers.h index a72e84bec..084e7cfef 100644 --- a/src/libecmaobjects/ecma-helpers.h +++ b/src/libecmaobjects/ecma-helpers.h @@ -56,6 +56,7 @@ extern ecma_value_t ecma_copy_value( const ecma_value_t value); extern void ecma_free_value( const ecma_value_t value); extern ecma_completion_value_t ecma_make_completion_value( ecma_completion_type_t type, ecma_value_t value, uint8_t target); +extern ecma_completion_value_t ecma_make_simple_completion_value( ecma_simple_value_t simple_value); extern ecma_completion_value_t ecma_make_throw_value( ecma_object_t *exception_p); extern ecma_completion_value_t ecma_make_empty_completion_value( void); extern ecma_completion_value_t ecma_copy_completion_value( ecma_completion_value_t value); @@ -64,8 +65,9 @@ extern void ecma_free_completion_value( ecma_completion_value_t completion_value extern bool ecma_is_completion_value_normal( ecma_completion_value_t value); extern bool ecma_is_completion_value_throw( ecma_completion_value_t value); extern bool ecma_is_completion_value_normal_simple_value( ecma_completion_value_t value, ecma_simple_value_t simple_value); -extern bool ecma_is_completion_value_normal_false( ecma_completion_value_t value); extern bool ecma_is_completion_value_normal_true( ecma_completion_value_t value); +extern bool ecma_is_completion_value_normal_false( ecma_completion_value_t value); +extern bool ecma_is_empty_completion_value( ecma_completion_value_t value); extern ecma_object_t* ecma_create_object( ecma_object_t *prototype_object_p, bool is_extensible); extern ecma_object_t* ecma_create_lexical_environment( ecma_object_t *outer_lexical_environment_p, ecma_lexical_environment_type_t type); diff --git a/src/libecmaoperations/ecma-conversion.c b/src/libecmaoperations/ecma-conversion.c index 6ddcd6b6f..0d0b0778f 100644 --- a/src/libecmaoperations/ecma-conversion.c +++ b/src/libecmaoperations/ecma-conversion.c @@ -44,25 +44,18 @@ ecma_op_check_object_coercible( ecma_value_t value) /**< ecma-value */ { case ECMA_TYPE_SIMPLE: { - switch ( (ecma_simple_value_t)value.value ) - { - case ECMA_SIMPLE_VALUE_UNDEFINED: - case ECMA_SIMPLE_VALUE_NULL: - { - return ecma_make_throw_value( ecma_new_standard_error( ECMA_ERROR_TYPE)); - } - case ECMA_SIMPLE_VALUE_FALSE: - case ECMA_SIMPLE_VALUE_TRUE: - { - break; - } - case ECMA_SIMPLE_VALUE_EMPTY: - case ECMA_SIMPLE_VALUE_ARRAY_REDIRECT: - case ECMA_SIMPLE_VALUE__COUNT: - { - JERRY_UNREACHABLE(); - } - } + if ( ecma_is_value_undefined( value) ) + { + return ecma_make_throw_value( ecma_new_standard_error( ECMA_ERROR_TYPE)); + } + else if ( ecma_is_value_boolean( value) ) + { + break; + } + else + { + JERRY_UNREACHABLE(); + } break; } @@ -130,8 +123,6 @@ ecma_op_to_primitive( ecma_value_t value, /**< ecma-value */ ecma_completion_value_t ecma_op_to_boolean( ecma_value_t value) /**< ecma-value */ { - ecma_simple_value_t res = ECMA_SIMPLE_VALUE_EMPTY; - switch ( (ecma_type_t)value.value_type ) { case ECMA_TYPE_NUMBER: @@ -139,8 +130,9 @@ ecma_op_to_boolean( ecma_value_t value) /**< ecma-value */ ecma_number_t *num_p = ecma_get_pointer( value.value); TODO( Implement according to ECMA ); - res = ( *num_p == 0 ) ? ECMA_SIMPLE_VALUE_FALSE: - ECMA_SIMPLE_VALUE_TRUE; + + return ecma_make_simple_completion_value( ( *num_p == 0 ) ? ECMA_SIMPLE_VALUE_FALSE + : ECMA_SIMPLE_VALUE_TRUE ); break; } @@ -148,11 +140,11 @@ ecma_op_to_boolean( ecma_value_t value) /**< ecma-value */ { if ( ecma_is_value_boolean (value ) ) { - res = value.value; + return ecma_make_simple_completion_value( value.value); } else if ( ecma_is_value_undefined (value) || ecma_is_value_null( value) ) { - res = ECMA_SIMPLE_VALUE_FALSE; + return ecma_make_simple_completion_value( ECMA_SIMPLE_VALUE_FALSE); } else { JERRY_UNREACHABLE(); @@ -164,14 +156,14 @@ ecma_op_to_boolean( ecma_value_t value) /**< ecma-value */ { ecma_array_first_chunk_t *str_p = ecma_get_pointer( value.value); - res = ( str_p->header.unit_number == 0 ) ? ECMA_SIMPLE_VALUE_FALSE: - ECMA_SIMPLE_VALUE_TRUE; + return ecma_make_simple_completion_value( ( str_p->header.unit_number == 0 ) ? ECMA_SIMPLE_VALUE_FALSE + : ECMA_SIMPLE_VALUE_TRUE ); break; } case ECMA_TYPE_OBJECT: { - res = ECMA_SIMPLE_VALUE_TRUE; + return ecma_make_simple_completion_value( ECMA_SIMPLE_VALUE_TRUE); break; } @@ -181,12 +173,7 @@ ecma_op_to_boolean( ecma_value_t value) /**< ecma-value */ } } - JERRY_ASSERT( res == ECMA_SIMPLE_VALUE_FALSE - || res == ECMA_SIMPLE_VALUE_TRUE ); - - return ecma_make_completion_value (ECMA_COMPLETION_TYPE_NORMAL, - ecma_make_simple_value( res), - ECMA_TARGET_ID_RESERVED); + JERRY_UNREACHABLE(); } /* ecma_op_to_boolean */ /** diff --git a/src/libecmaoperations/ecma-lex-env.c b/src/libecmaoperations/ecma-lex-env.c index de7921f2c..dbc421ea2 100644 --- a/src/libecmaoperations/ecma-lex-env.c +++ b/src/libecmaoperations/ecma-lex-env.c @@ -186,8 +186,7 @@ ecma_op_get_binding_value(ecma_object_t *lex_env_p, /**< lexical environment */ return ecma_make_completion_value( ECMA_COMPLETION_TYPE_NORMAL, ecma_copy_value( prop_value), ECMA_TARGET_ID_RESERVED); - } else if ( prop_value.value_type == ECMA_TYPE_SIMPLE - && prop_value.value == ECMA_SIMPLE_VALUE_EMPTY ) + } else if ( ecma_is_value_empty( prop_value) ) { /* unitialized immutable binding */ if ( is_strict ) @@ -318,13 +317,14 @@ ecma_op_create_immutable_binding(ecma_object_t *lex_env_p, /**< lexical environm * Whether immutable bindings are deletable seems not to be defined by ECMA v5. */ ecma_property_t *prop_p = ecma_create_named_property( lex_env_p, - name_p, - ECMA_PROPERTY_NOT_WRITABLE, - ECMA_PROPERTY_NOT_ENUMERABLE, - ECMA_PROPERTY_NOT_CONFIGURABLE); + name_p, + ECMA_PROPERTY_NOT_WRITABLE, + ECMA_PROPERTY_NOT_ENUMERABLE, + ECMA_PROPERTY_NOT_CONFIGURABLE); - JERRY_ASSERT( prop_p->u.named_data_property.value.value_type == ECMA_TYPE_SIMPLE ); + JERRY_ASSERT( ecma_is_value_undefined( prop_p->u.named_data_property.value ) ); + prop_p->u.named_data_property.value.value_type = ECMA_TYPE_SIMPLE; prop_p->u.named_data_property.value.value = ECMA_SIMPLE_VALUE_EMPTY; } case ECMA_LEXICAL_ENVIRONMENT_OBJECTBOUND: @@ -358,8 +358,7 @@ ecma_op_initialize_immutable_binding(ecma_object_t *lex_env_p, /**< lexical envi /* The binding must be unitialized immutable binding */ JERRY_ASSERT( prop_p->u.named_data_property.writable == ECMA_PROPERTY_NOT_WRITABLE - && prop_p->u.named_data_property.value.value_type == ECMA_TYPE_SIMPLE - && prop_p->u.named_data_property.value.value == ECMA_SIMPLE_VALUE_EMPTY ); + && ecma_is_value_empty( prop_p->u.named_data_property.value) ); prop_p->u.named_data_property.value = ecma_copy_value( value); } From b073701da47b155051c73f427c237c40feb96004 Mon Sep 17 00:00:00 2001 From: Ruben Ayrapetyan Date: Mon, 28 Jul 2014 21:54:42 +0400 Subject: [PATCH 2/3] Introducing ECMA property descriptor (8.10) type and helpers for it: constructor and destructor. --- src/libecmaobjects/ecma-globals.h | 46 +++++++++++++++- src/libecmaobjects/ecma-helpers.c | 90 +++++++++++++++++++++++++++++++ src/libecmaobjects/ecma-helpers.h | 15 ++++++ 3 files changed, 150 insertions(+), 1 deletion(-) diff --git a/src/libecmaobjects/ecma-globals.h b/src/libecmaobjects/ecma-globals.h index c58b3e61d..a416f27f9 100644 --- a/src/libecmaobjects/ecma-globals.h +++ b/src/libecmaobjects/ecma-globals.h @@ -189,7 +189,51 @@ typedef enum } ecma_property_configurable_value_t; /** - * Description of ecma-property. + * Description of ECMA property descriptor + * + * See also: ECMA-262 v5, 8.10. + */ +typedef struct +{ + /** Is [[Value]] defined? */ + unsigned int is_value_defined : 1; + + /** Is [[Get]] defined? */ + unsigned int is_get_defined : 1; + + /** Is [[Set]] defined? */ + unsigned int is_set_defined : 1; + + /** Is [[Writable]] defined? */ + unsigned int is_writable_defined : 1; + + /** Is [[Enumerable]] defined? */ + unsigned int is_enumerable_defined : 1; + + /** Is [[Configurable]] defined? */ + unsigned int is_configurable_defined : 1; + + /** [[Value]] */ + ecma_value_t value; + + /** [[Get]] */ + ecma_value_t get; + + /** [[Set]] */ + ecma_value_t set; + + /** [[Writable]] */ + ecma_property_writable_value_t writable; + + /** [[Enumerable]] */ + ecma_property_enumerable_value_t enumerable; + + /** [[Configurable]] */ + ecma_property_configurable_value_t configurable; +} ecma_property_descriptor_t; + +/** + * Description of ecma-property */ typedef struct ecma_property_t { /** Property's type (ecma_property_type_t) */ diff --git a/src/libecmaobjects/ecma-helpers.c b/src/libecmaobjects/ecma-helpers.c index 2ffa90248..199c8f5cf 100644 --- a/src/libecmaobjects/ecma-helpers.c +++ b/src/libecmaobjects/ecma-helpers.c @@ -700,6 +700,96 @@ ecma_free_array( ecma_array_first_chunk_t *first_chunk_p) /**< first chunk of th } } /* ecma_free_array */ +/** + * ECMA property descriptor constructor. + * + * @return ecma property descriptor + */ +ecma_property_descriptor_t +ecma_make_property_descriptor( bool is_value_defined, /**< is [[Value]] defined */ + bool is_get_defined, /**< is [[Get]] defined */ + bool is_set_defined, /**< is [[Set]] defined */ + bool is_writable_defined, /**< is [[Writable]] defined */ + bool is_enumerable_defined, /**< is [[Enumerable]] defined */ + bool is_configurable_defined, /**< is [[Configurable]] defined */ + ecma_value_t value, /**< [[Value]] */ + ecma_value_t get, /**< [[Get]] */ + ecma_value_t set, /**< [[Set]] */ + ecma_property_writable_value_t writable, /**< [[Writable]] */ + ecma_property_enumerable_value_t enumerable, /**< [[Enumerable]] */ + ecma_property_configurable_value_t configurable) /**< [[Configurable]] */ +{ + ecma_property_descriptor_t prop_desc; + + prop_desc.is_value_defined = is_value_defined; + prop_desc.is_get_defined = is_get_defined; + prop_desc.is_set_defined = is_set_defined; + prop_desc.is_writable_defined = is_writable_defined; + prop_desc.is_enumerable_defined = is_enumerable_defined; + prop_desc.is_configurable_defined = is_configurable_defined; + + if ( prop_desc.is_value_defined ) + { + prop_desc.value = value; + } + + if ( prop_desc.is_get_defined ) + { + prop_desc.get = get; + } + + if ( prop_desc.is_set_defined ) + { + prop_desc.set = set; + } + + if ( prop_desc.is_writable_defined ) + { + prop_desc.writable = writable; + } + + if ( prop_desc.is_enumerable_defined ) + { + prop_desc.enumerable = enumerable; + } + + if ( prop_desc.is_configurable_defined ) + { + prop_desc.configurable = configurable; + } + + return prop_desc; +} /* ecma_make_property_descriptor */ + +/** + * Free the ecma property descriptor. + */ +void +ecma_free_property_descriptor( ecma_property_descriptor_t prop_desc) /**< ECMA property descriptor */ +{ + if ( prop_desc.is_value_defined ) + { + ecma_free_value( prop_desc.value); + } + + if ( prop_desc.is_get_defined ) + { + ecma_free_value( prop_desc.get); + } + + if ( prop_desc.is_set_defined ) + { + ecma_free_value( prop_desc.set); + } + + prop_desc.is_value_defined = false; + prop_desc.is_get_defined = false; + prop_desc.is_set_defined = false; + prop_desc.is_writable_defined = false; + prop_desc.is_enumerable_defined = false; + prop_desc.is_configurable_defined = false; +} /* ecma_free_property_descriptor */ + /** * @} * @} diff --git a/src/libecmaobjects/ecma-helpers.h b/src/libecmaobjects/ecma-helpers.h index 084e7cfef..7e6472c64 100644 --- a/src/libecmaobjects/ecma-helpers.h +++ b/src/libecmaobjects/ecma-helpers.h @@ -96,6 +96,21 @@ extern bool ecma_compare_zt_string_to_ecma_string( const ecma_char_t *string_p, extern bool ecma_compare_ecma_string_to_ecma_string(const ecma_array_first_chunk_t *string1_p, const ecma_array_first_chunk_t *string2_p); extern void ecma_free_array( ecma_array_first_chunk_t *first_chunk_p); +extern ecma_property_descriptor_t ecma_make_property_descriptor( bool is_value_defined, + bool is_get_defined, + bool is_set_defined, + bool is_writable_defined, + bool is_enumerable_defined, + bool is_configurable_defined, + ecma_value_t value, + ecma_value_t get, + ecma_value_t set, + ecma_property_writable_value_t writable, + ecma_property_enumerable_value_t enumerable, + ecma_property_configurable_value_t configurable); + +extern void ecma_free_property_descriptor( ecma_property_descriptor_t prop_desc); + #endif /* !JERRY_ECMA_HELPERS_H */ /** From 4cefa6950e7700c12755df5b9dc58b123249080b Mon Sep 17 00:00:00 2001 From: Ruben Ayrapetyan Date: Mon, 28 Jul 2014 21:57:27 +0400 Subject: [PATCH 3/3] Fix ecma_op_define_own_property argument list: the routine now takes property descriptor as an argument instead of property. --- src/libecmaoperations/ecma-objects-properties.c | 2 +- src/libecmaoperations/ecma-objects-properties.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/libecmaoperations/ecma-objects-properties.c b/src/libecmaoperations/ecma-objects-properties.c index 21b17175c..104549285 100644 --- a/src/libecmaoperations/ecma-objects-properties.c +++ b/src/libecmaoperations/ecma-objects-properties.c @@ -166,7 +166,7 @@ ecma_op_object_default_value( ecma_object_t *obj_p, /**< the object */ ecma_completion_value_t ecma_op_object_define_own_property( ecma_object_t *obj_p, /**< the object */ ecma_array_first_chunk_t *property_name_p, /**< property name */ - ecma_property_t property_desc, /**< property descriptor */ + ecma_property_descriptor_t property_desc, /**< property descriptor */ bool is_throw) /**< flag that controls failure handling */ { JERRY_UNIMPLEMENTED_REF_UNUSED_VARS( obj_p, property_name_p, property_desc, is_throw); diff --git a/src/libecmaoperations/ecma-objects-properties.h b/src/libecmaoperations/ecma-objects-properties.h index ad31a42c9..a5f65a0a4 100644 --- a/src/libecmaoperations/ecma-objects-properties.h +++ b/src/libecmaoperations/ecma-objects-properties.h @@ -41,7 +41,7 @@ extern ecma_completion_value_t ecma_op_object_delete( ecma_object_t *obj_p, extern ecma_completion_value_t ecma_op_object_default_value( ecma_object_t *obj_p, ecma_preferred_type_hint_t hint); extern ecma_completion_value_t ecma_op_object_define_own_property( ecma_object_t *obj_p, ecma_array_first_chunk_t *property_name_p, - ecma_property_t property_desc, + ecma_property_descriptor_t property_desc, bool is_throw); /**