Implement array/object destructuring (#3305)
This patch implements the core functionality of destructuring patterns. Function argument/for in-of pattern are currently unsupported. JerryScript-DCO-1.0-Signed-off-by: Zoltan Herczeg zherczeg.u-szeged@partner.samsung.com JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu
This commit is contained in:
committed by
Zoltan Herczeg
parent
b4b55a67a2
commit
213544ae47
@@ -2369,7 +2369,7 @@ lexer_expect_object_literal_id (parser_context_t *context_p, /**< context */
|
||||
{
|
||||
lexer_parse_identifier (context_p, false);
|
||||
|
||||
if (!(ident_opts & LEXER_OBJ_IDENT_ONLY_IDENTIFIERS)
|
||||
if (!(ident_opts & (LEXER_OBJ_IDENT_ONLY_IDENTIFIERS | LEXER_OBJ_IDENT_OBJECT_PATTERN))
|
||||
&& context_p->token.lit_location.length == 3)
|
||||
{
|
||||
lexer_skip_spaces (context_p);
|
||||
|
||||
Reference in New Issue
Block a user