mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 04:17:35 +00:00
LibJS: Validate all assignment expressions, not just "="
The check for invalid lhs and assignment to eval/arguments in strict mode should happen for all kinds of assignment expressions, not just AssignmentOp::Assignment.
This commit is contained in:
parent
e80217a746
commit
283ee678f7
3 changed files with 56 additions and 39 deletions
|
@ -84,6 +84,7 @@ public:
|
|||
NonnullRefPtr<ClassDeclaration> parse_class_declaration();
|
||||
NonnullRefPtr<ClassExpression> parse_class_expression(bool expect_class_name);
|
||||
NonnullRefPtr<Expression> parse_property_key();
|
||||
NonnullRefPtr<AssignmentExpression> parse_assignment_expression(AssignmentOp, NonnullRefPtr<Expression> lhs, int min_precedence, Associativity);
|
||||
|
||||
struct Error {
|
||||
String message;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue