Partially implementing ToNumber operation.

This commit is contained in:
Ruben Ayrapetyan
2014-07-21 20:35:44 +04:00
parent 7a0612d441
commit 9b2b248728
5 changed files with 64 additions and 6 deletions
+12
View File
@@ -276,6 +276,18 @@ ecma_free_completion_value( ecma_CompletionValue_t completion_value) /**< comple
}
} /* ecma_free_completion_value */
/**
* Check if the completion value is normal value.
*
* @return true - if the completion type is normal,
* false - otherwise.
*/
bool
ecma_is_completion_value_normal( ecma_CompletionValue_t value)
{
return ( value.type == ECMA_COMPLETION_TYPE_NORMAL );
} /* ecma_is_completion_value_normal */
/**
* Check if the completion value is specified normal simple value.
*
+1
View File
@@ -56,6 +56,7 @@ extern ecma_CompletionValue_t ecma_MakeCompletionValue( ecma_CompletionType_t ty
extern ecma_CompletionValue_t ecma_MakeThrowValue( ecma_Object_t *exception_p);
extern void ecma_free_completion_value( ecma_CompletionValue_t completion_value);
extern bool ecma_is_completion_value_normal( ecma_CompletionValue_t value);
extern bool ecma_is_completion_value_normal_simple_value( ecma_CompletionValue_t value, ecma_SimpleValue_t simple_value);
extern bool ecma_IsCompletionValueNormalFalse( ecma_CompletionValue_t value);
extern bool ecma_IsCompletionValueNormalTrue( ecma_CompletionValue_t value);