Repository: jerryscript-project/jerryscript
File: jerry-core/ecma/base/ecma-helpers-value.c (C)

Code before:
 */
inline bool JERRY_ATTR_CONST JERRY_ATTR_ALWAYS_INLINE
ecma_is_value_symbol (ecma_value_t value) /**< ecma value */
{
  return (ecma_get_value_type_field (value) == ECMA_TYPE_SYMBOL);
} /* ecma_is_value_symbol */
#endif /* ENABLED (JERRY_ESNEXT) */

/**
 * Check if the value is bigint.
 *
 * @return true - if the value contains bigint value,
 *         false - otherwise
 */
inline bool JERRY_ATTR_CONST JERRY_ATTR_ALWAYS_INLINE
ecma_is_value_bigint (ecma_value_t value) /**< ecma value */
{
  #if ENABLED (JERRY_BUILTIN_BIGINT)
  return (ecma_get_value_type_field (value) == ECMA_TYPE_BIGINT);
  #else /* !ENABLED (JERRY_BUILTIN_BIGINT) */
  JERRY_UNUSED (value);
  return false;
  #endif /* ENABLED (JERRY_BUILTIN_BIGINT) */
} /* ecma_is_value_bigint */

/**
 * Check if the value can be property name.
 *
 * @return true - if the value can be property name value,
 *         false - otherwise
 */
inline bool JERRY_ATTR_CONST JERRY_ATTR_ALWAYS_INLINE
ecma_is_value_prop_name (ecma_value_t value) /**< ecma value */
{
#if ENABLED (JERRY_ESNEXT)
  return ecma_is_value_string (value) || ecma_is_value_symbol (value);
#else /* !ENABLED (JERRY_ESNEXT) */
  return ecma_is_value_string (value);
#endif /* ENABLED (JERRY_ESNEXT) */
} /* ecma_is_value_prop_name */

/**
 * Check if the value is direct ecma-string.
 *
 * @return true - if the value contains direct ecma-string value,
 *         false - otherwise
 */
inline bool JERRY_ATTR_CONST JERRY_ATTR_ALWAYS_INLINE
ecma_is_value_direct_string (ecma_value_t value) /**< ecma value */
{
  return (ecma_get_value_type_field (value) == ECMA_TYPE_DIRECT_STRING);

Review comment (suggestion):
Now you can remove `ECMA_CHECK_BIGINT_IN_ASSERT`.

Also this whole can can be performed for `ecma_is_value_symbol` as well. (same for ECMA_CHECK_SYMBOL_IN_ASSERT)

Code after:
inline bool JERRY_ATTR_CONST JERRY_ATTR_ALWAYS_INLINE
ecma_is_value_symbol (ecma_value_t value) /**< ecma value */
{
#if ENABLED (JERRY_ESNEXT)
  return (ecma_get_value_type_field (value) == ECMA_TYPE_SYMBOL);
#else /* ENABLED (JERRY_ESNEXT) */
  JERRY_UNUSED (value);
  return false;
#endif /* ENABLED (JERRY_ESNEXT) */
} /* ecma_is_value_symbol */

/**
 * Check if the value is bigint.
 *
 * @return true - if the value contains bigint value,
 *         false - otherwise
 */
inline bool JERRY_ATTR_CONST JERRY_ATTR_ALWAYS_INLINE
ecma_is_value_bigint (ecma_value_t value) /**< ecma value */
{
  #if ENABLED (JERRY_BUILTIN_BIGINT)
  return (ecma_get_value_type_field (value) == ECMA_TYPE_BIGINT);
  #else /* !ENABLED (JERRY_BUILTIN_BIGINT) */
  JERRY_UNUSED (value);
  return false;
  #endif /* ENABLED (JERRY_BUILTIN_BIGINT) */
} /* ecma_is_value_bigint */

/**
 * Check if the value can be property name.
 *
 * @return true - if the value can be property name value,
 *         false - otherwise
 */
inline bool JERRY_ATTR_CONST JERRY_ATTR_ALWAYS_INLINE
ecma_is_value_prop_name (ecma_value_t value) /**< ecma value */
{
#if ENABLED (JERRY_ESNEXT)
  return ecma_is_value_string (value) || ecma_is_value_symbol (value);
#else /* !ENABLED (JERRY_ESNEXT) */
  return ecma_is_value_string (value);
#endif /* ENABLED (JERRY_ESNEXT) */
} /* ecma_is_value_prop_name */

/**
 * Check if the value is direct ecma-string.
 *
 * @return true - if the value contains direct ecma-string value,
 *         false - otherwise
 */
inline bool JERRY_ATTR_CONST JERRY_ATTR_ALWAYS_INLINE