Support parsing async modifiers for functions. (#3460)
Only parsing is implemented, so the async functions currently behave like normal function except they return with a resolved Promise object when the function is terminated correctly. JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg zherczeg.u-szeged@partner.samsung.com
This commit is contained in:
@@ -210,6 +210,10 @@ typedef enum
|
||||
typedef enum
|
||||
{
|
||||
SCANNER_FUNCTION_ARGUMENTS_NEEDED = (1 << 0), /**< arguments object needs to be created */
|
||||
#if ENABLED (JERRY_ES2015)
|
||||
SCANNER_FUNCTION_STATEMENT = (1 << 1), /**< function is (async) function statement */
|
||||
SCANNER_FUNCTION_ASYNC = (1 << 2), /**< function is async function expression */
|
||||
#endif /* ENABLED (JERRY_ES2015) */
|
||||
} scanner_function_flags_t;
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user