Implement rest parameter support for destructuring object patterns. (#4318)

JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg zherczeg.u-szeged@partner.samsung.com
This commit is contained in:
Zoltan Herczeg
2020-10-29 10:49:08 +01:00
committed by GitHub
parent 484e999dec
commit c7986fd2c5
22 changed files with 632 additions and 528 deletions
+1 -1
View File
@@ -3334,7 +3334,7 @@ lexer_expect_object_literal_id (parser_context_t *context_p, /**< context */
}
case LIT_CHAR_DOT:
{
if (ident_opts != LEXER_OBJ_IDENT_NO_OPTS
if ((ident_opts & ((uint32_t) ~LEXER_OBJ_IDENT_OBJECT_PATTERN))
|| context_p->source_p + 2 >= context_p->source_end_p
|| context_p->source_p[1] != LIT_CHAR_DOT
|| context_p->source_p[2] != LIT_CHAR_DOT)