Rename ecma_is_value_error to ECMA_IS_VALUE_ERROR.

JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg zherczeg.u-szeged@partner.samsung.com
This commit is contained in:
Zoltan Herczeg
2016-06-10 01:04:08 -07:00
parent 1eeed7e07e
commit b828d4a463
28 changed files with 147 additions and 154 deletions
+45 -45
View File
@@ -113,7 +113,7 @@ vm_op_get_value (ecma_value_t object, /**< base object */
ecma_value_t prop_to_string_result = ecma_op_to_string (property);
if (ecma_is_value_error (prop_to_string_result))
if (ECMA_IS_VALUE_ERROR (prop_to_string_result))
{
return prop_to_string_result;
}
@@ -221,7 +221,7 @@ vm_run_global (ecma_value_t *error_value_p) /**< [out] error value */
NULL,
0);
if (ecma_is_value_error (ret_value))
if (ECMA_IS_VALUE_ERROR (ret_value))
{
*error_value_p = ret_value;
ret_code = JERRY_COMPLETION_CODE_UNHANDLED_EXCEPTION;
@@ -317,7 +317,7 @@ vm_construct_literal_object (vm_frame_ctx_t *frame_ctx_p, /**< frame context */
ecma_value_t ret_value;
ret_value = ecma_op_create_regexp_object_from_bytecode ((re_compiled_code_t *) bytecode_p);
if (ecma_is_value_error (ret_value))
if (ECMA_IS_VALUE_ERROR (ret_value))
{
/* TODO: throw exception instead of define an 'undefined' value. */
return ecma_make_simple_value (ECMA_SIMPLE_VALUE_UNDEFINED);
@@ -347,7 +347,7 @@ vm_get_implicit_this_value (ecma_value_t *this_value_p) /**< [in,out] this value
{
ecma_value_t completion_value = ecma_op_implicit_this_value (this_obj_p);
JERRY_ASSERT (!ecma_is_value_error (completion_value));
JERRY_ASSERT (!ECMA_IS_VALUE_ERROR (completion_value));
*this_value_p = completion_value;
return true;
@@ -520,7 +520,7 @@ opfunc_construct (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
\
ecma_deref_ecma_string (name_p); \
\
if (ecma_is_value_error (result)) \
if (ECMA_IS_VALUE_ERROR (result)) \
{ \
goto error; \
} \
@@ -974,7 +974,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = ecma_op_to_string (right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1020,7 +1020,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = ecma_op_create_array_object (NULL, 0, false);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1125,7 +1125,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
result = ecma_raise_reference_error (ECMA_ERR_MSG (""));
}
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
ecma_deref_ecma_string (name_p);
goto error;
@@ -1171,7 +1171,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
result = vm_op_get_value (left_value,
right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
if (opcode >= CBC_PUSH_PROP_REFERENCE && opcode < CBC_PRE_INCR)
{
@@ -1205,7 +1205,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
result = ecma_op_to_number (left_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1404,7 +1404,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
result = *(--stack_top_p);
block_result = frame_ctx_p->call_block_result;
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1445,7 +1445,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
result = *(--stack_top_p);
block_result = frame_ctx_p->call_block_result;
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1457,7 +1457,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = vm_op_delete_prop (left_value, right_value, is_strict);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1483,7 +1483,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
frame_ctx_p->lex_env_p,
is_strict);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1545,7 +1545,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = opfunc_unary_plus (left_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1557,7 +1557,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = opfunc_unary_minus (left_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1569,7 +1569,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = opfunc_logical_not (left_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1583,7 +1583,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
left_value,
left_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1628,7 +1628,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
ecma_deref_ecma_string (name_p);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1641,7 +1641,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = opfunc_typeof (left_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1653,7 +1653,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = opfunc_addition (left_value, right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1665,7 +1665,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
left_value,
right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1677,7 +1677,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
left_value,
right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1689,7 +1689,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
left_value,
right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1701,7 +1701,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
left_value,
right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1711,7 +1711,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = opfunc_equal_value (left_value, right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1723,7 +1723,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = opfunc_not_equal_value (left_value, right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1757,7 +1757,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
left_value,
right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1769,7 +1769,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
left_value,
right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1781,7 +1781,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
left_value,
right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1793,7 +1793,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
left_value,
right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1805,7 +1805,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
left_value,
right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1817,7 +1817,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
left_value,
right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1827,7 +1827,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = opfunc_less_than (left_value, right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1839,7 +1839,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = opfunc_greater_than (left_value, right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1851,7 +1851,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = opfunc_less_or_equal_than (left_value, right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1863,7 +1863,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = opfunc_greater_or_equal_than (left_value, right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1875,7 +1875,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = opfunc_in (left_value, right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1887,7 +1887,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
{
result = opfunc_instanceof (left_value, right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -1908,7 +1908,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
result = ecma_op_to_object (value);
ecma_free_value (value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
goto error;
}
@@ -2171,7 +2171,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
ecma_deref_ecma_string (var_name_str_p);
if (ecma_is_value_error (put_value_result))
if (ECMA_IS_VALUE_ERROR (put_value_result))
{
ecma_free_value (result);
result = put_value_result;
@@ -2210,7 +2210,7 @@ vm_loop (vm_frame_ctx_t *frame_ctx_p) /**< frame context */
ecma_free_value (object);
ecma_free_value (property);
if (ecma_is_value_error (set_value_result))
if (ECMA_IS_VALUE_ERROR (set_value_result))
{
ecma_free_value (result);
result = set_value_result;
@@ -2244,7 +2244,7 @@ error:
ecma_fast_free_value (left_value);
ecma_fast_free_value (right_value);
if (ecma_is_value_error (result))
if (ECMA_IS_VALUE_ERROR (result))
{
ecma_value_t *vm_stack_p = stack_top_p;
@@ -2276,7 +2276,7 @@ error:
return result;
}
if (!ecma_is_value_error (result))
if (!ECMA_IS_VALUE_ERROR (result))
{
JERRY_ASSERT (frame_ctx_p->registers_p + register_end + frame_ctx_p->context_depth == stack_top_p);
@@ -2412,7 +2412,7 @@ vm_execute (vm_frame_ctx_t *frame_ctx_p, /**< frame context */
completion_value = vm_init_loop (frame_ctx_p);
if (likely (!ecma_is_value_error (completion_value)))
if (!ECMA_IS_VALUE_ERROR (completion_value))
{
while (true)
{