Skip to content

Commit

Permalink
Add symbol support to same_value function (#3030)
Browse files Browse the repository at this point in the history
JerryScript-DCO-1.0-Signed-off-by: Daniel Balla [email protected]
  • Loading branch information
Daniel Balla authored and rerobika committed Sep 2, 2019
1 parent ea77a79 commit 2975810
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions jerry-core/ecma/operations/ecma-conversion.c
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,12 @@ ecma_op_same_value (ecma_value_t x, /**< ecma value */
{
return (ecma_is_value_true (x) == ecma_is_value_true (y));
}
#if ENABLED (JERRY_ES2015_BUILTIN_SYMBOL)
else if (ecma_is_value_symbol (x))
{
return x == y;
}
#endif /* ENABLED (JERRY_ES2015_BUILTIN_SYMBOL) */
else
{
JERRY_ASSERT (is_x_object);
Expand Down

0 comments on commit 2975810

Please sign in to comment.