Fix class constructor as accessor check (#4880)
This patch fixes #4874. JerryScript-DCO-1.0-Signed-off-by: Robert Fancsik robert.fancsik@h-lab.eu
This commit is contained in:
@@ -726,7 +726,7 @@ parser_parse_class_body (parser_context_t *context_p, /**< context */
|
||||
}
|
||||
else if (parser_is_constructor_literal (context_p))
|
||||
{
|
||||
JERRY_ASSERT (!is_static);
|
||||
JERRY_ASSERT (!is_static || is_private);
|
||||
parser_raise_error (context_p, PARSER_ERR_CLASS_CONSTRUCTOR_AS_ACCESSOR);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user