mirror of
https://github.com/RGBCube/serenity
synced 2025-05-30 22:38:12 +00:00
LibJS: Handle "for" statements with empty initializer and updater
This commit is contained in:
parent
30d24af54a
commit
6c9d2cfa5e
3 changed files with 26 additions and 2 deletions
|
@ -612,7 +612,7 @@ NonnullRefPtr<ForStatement> Parser::parse_for_statement()
|
|||
|
||||
RefPtr<Expression> update;
|
||||
switch (m_current_token.type()) {
|
||||
case TokenType::Semicolon:
|
||||
case TokenType::ParenClose:
|
||||
break;
|
||||
default:
|
||||
update = parse_expression(0);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue