@@ -1581,14 +1581,14 @@ parser_check_assignment_expr (parser_context_t *context_p)
15811581} /* parser_check_assignment_expr */
15821582
15831583/**
1584- * Checks whether the next token is a valid continuation token after an arrow function .
1584+ * Checks whether the next token is a valid continuation token after an AssignmentExpression .
15851585 */
15861586static inline bool JERRY_ATTR_ALWAYS_INLINE
1587- parser_abort_parsing_after_arrow (parser_context_t * context_p )
1587+ parser_abort_parsing_after_assignment_expression (parser_context_t * context_p )
15881588{
15891589 return (context_p -> token .type != LEXER_RIGHT_PAREN
15901590 && context_p -> token .type != LEXER_COMMA );
1591- } /* parser_abort_parsing_after_arrow */
1591+ } /* parser_abort_parsing_after_assignment_expression */
15921592
15931593#endif /* ENABLED (JERRY_ES2015) */
15941594
@@ -1732,7 +1732,7 @@ parser_parse_unary_expression (parser_context_t *context_p, /**< context */
17321732
17331733 parser_check_assignment_expr (context_p );
17341734 parser_parse_function_expression (context_p , arrow_status_flags );
1735- return parser_abort_parsing_after_arrow (context_p );
1735+ return parser_abort_parsing_after_assignment_expression (context_p );
17361736 }
17371737#endif /* ENABLED (JERRY_ES2015) */
17381738
@@ -1828,7 +1828,7 @@ parser_parse_unary_expression (parser_context_t *context_p, /**< context */
18281828 if (parser_is_assignment_expr (context_p ))
18291829 {
18301830 parser_parse_object_initializer (context_p , PARSER_PATTERN_NO_OPTS );
1831- return false ;
1831+ return parser_abort_parsing_after_assignment_expression ( context_p ) ;
18321832 }
18331833
18341834 scanner_release_next (context_p , sizeof (scanner_location_info_t ));
@@ -1848,7 +1848,7 @@ parser_parse_unary_expression (parser_context_t *context_p, /**< context */
18481848 if (parser_is_assignment_expr (context_p ))
18491849 {
18501850 parser_parse_array_initializer (context_p , PARSER_PATTERN_NO_OPTS );
1851- return false ;
1851+ return parser_abort_parsing_after_assignment_expression ( context_p ) ;
18521852 }
18531853
18541854 scanner_release_next (context_p , sizeof (scanner_location_info_t ));
@@ -1949,7 +1949,7 @@ parser_parse_unary_expression (parser_context_t *context_p, /**< context */
19491949 parser_check_assignment_expr (context_p );
19501950
19511951 parser_parse_function_expression (context_p , PARSER_IS_FUNCTION | PARSER_IS_ARROW_FUNCTION );
1952- return parser_abort_parsing_after_arrow (context_p );
1952+ return parser_abort_parsing_after_assignment_expression (context_p );
19531953 }
19541954 case LEXER_KEYW_YIELD :
19551955 {
0 commit comments