Rework built-in processing of JerryScript (#4347)

- All built-ins are native functions now
- Native handlers have a built-in id: ECMA_BUILTIN_ID_HANDLER
- Built-in routine identifiers start from 1
- Built-in routines have an own flag set
- Name property of routines is resolved dynamically
- Style fixes

JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg zherczeg.u-szeged@partner.samsung.com
This commit is contained in:
Zoltan Herczeg
2020-12-01 11:37:08 +01:00
committed by GitHub
parent 577a605ead
commit c0fc67f5bd
39 changed files with 441 additions and 442 deletions
@@ -47,7 +47,7 @@
*/
enum
{
ECMA_MATH_OBJECT_ROUTINE_START = ECMA_BUILTIN_ID__COUNT - 1,
ECMA_MATH_OBJECT_ROUTINE_START = 0,
ECMA_MATH_OBJECT_ABS, /* ECMA-262 v5, 15.8.2.1 */
ECMA_MATH_OBJECT_ACOS, /* ECMA-262 v5, 15.8.2.2 */
@@ -328,8 +328,7 @@ ecma_builtin_math_object_random (void)
* Returned value must be freed with ecma_free_value.
*/
ecma_value_t
ecma_builtin_math_dispatch_routine (uint16_t builtin_routine_id, /**< built-in wide routine
* identifier */
ecma_builtin_math_dispatch_routine (uint8_t builtin_routine_id, /**< built-in wide routine identifier */
ecma_value_t this_arg, /**< 'this' argument value */
const ecma_value_t arguments_list[], /**< list of arguments
* passed to routine */