Implement generator support for object initializers and classes. (#3372)

Large part of the code is also reworked.

JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg zherczeg.u-szeged@partner.samsung.com
This commit is contained in:
Zoltan Herczeg
2019-11-29 12:28:51 +01:00
committed by Dániel Bátyai
parent 1b01bb034f
commit 8956eff2bd
7 changed files with 411 additions and 185 deletions
@@ -121,6 +121,11 @@ typedef enum
*/
#define PARSER_STRICT_MODE_MASK 0x1
/**
* Shorthand for function closure definition
*/
#define PARSER_FUNCTION_CLOSURE (PARSER_IS_FUNCTION | PARSER_IS_CLOSURE)
#if ENABLED (JERRY_ES2015)
/**
* Offset between PARSER_CLASS_CONSTRUCTOR and ECMA_PARSE_CLASS_CONSTRUCTOR
@@ -183,6 +188,7 @@ typedef enum
#define PARSER_CBC_STREAM_PAGE_SIZE \
((uint32_t) (64 - sizeof (void *)))
/* Defines the size of the max page. */
#define PARSER_STACK_PAGE_SIZE \
((uint32_t) (((sizeof (void *) > 4) ? 128 : 64) - sizeof (void *)))