Implement ECMAScript 2022 class static block (#4841)

Co-authored-by: Martin Negyokru negyokru@inf.u-szeged.hu
JerryScript-DCO-1.0-Signed-off-by: Adam Szilagyi aszilagy@inf.u-szeged.hu
This commit is contained in:
Szilagyi Adam
2021-12-15 15:45:53 +01:00
committed by GitHub
parent c51b268276
commit 53b61c1f6f
15 changed files with 381 additions and 46 deletions
+6
View File
@@ -3090,6 +3090,12 @@ parser_parse_statements (parser_context_t *context_p) /**< context */
{
parser_raise_error (context_p, PARSER_ERR_INVALID_RETURN);
}
#if JERRY_ESNEXT
if (context_p->status_flags & PARSER_IS_CLASS_STATIC_BLOCK)
{
parser_raise_error (context_p, PARSER_ERR_INVALID_RETURN);
}
#endif /* JERRY_ESNEXT */
lexer_next_token (context_p);