Fix super property reference parsing (#2672)
`PARSER_CLASS_SUPER_PROP_REFERENCE` flag should be applied for only binary lvalue tokens. This patch fixed #2671. JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik frobert@inf.u-szeged.hu
This commit is contained in:
committed by
Zoltan Herczeg
parent
7b48be81c3
commit
ef2c3b46d7
@@ -1409,7 +1409,7 @@ parser_parse_unary_expression (parser_context_t *context_p, /**< context */
|
||||
|| lexer_check_next_character (context_p, LIT_CHAR_LEFT_SQUARE))
|
||||
&& context_p->status_flags & (PARSER_CLASS_HAS_SUPER | PARSER_IS_ARROW_FUNCTION))
|
||||
{
|
||||
if (!LEXER_IS_BINARY_OP_TOKEN (context_p->stack_top_uint8))
|
||||
if (!LEXER_IS_BINARY_LVALUE_TOKEN (context_p->stack_top_uint8))
|
||||
{
|
||||
context_p->status_flags |= PARSER_CLASS_SUPER_PROP_REFERENCE;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user