From 7d420bbd3d89903d9fd1a614dfb2996700eb61d8 Mon Sep 17 00:00:00 2001 From: Timothy Flynn Date: Mon, 20 Jan 2025 11:14:03 -0500 Subject: [PATCH] LibJS: Update the noted grammar for ImportDeclaration --- Libraries/LibJS/Parser.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Libraries/LibJS/Parser.cpp b/Libraries/LibJS/Parser.cpp index 8b0d043062..a546c6bcdb 100644 --- a/Libraries/LibJS/Parser.cpp +++ b/Libraries/LibJS/Parser.cpp @@ -4631,10 +4631,10 @@ static DeprecatedFlyString default_string_value = "default"; NonnullRefPtr Parser::parse_import_statement(Program& program) { // We use the extended syntax which adds: - // ImportDeclaration: - // import ImportClause FromClause [no LineTerminator here] WithClause; - // import ModuleSpecifier [no LineTerminator here] WithClause; - // From: https://tc39.es/proposal-import-attributes/#prod-ImportDeclaration + // ImportDeclaration: + // import ImportClause FromClause WithClause[opt] ; + // import ModuleSpecifier WithClause[opt] ; + // From: https://tc39.es/proposal-import-attributes/#prod-ImportDeclaration auto rule_start = push_start(); if (program.type() != Program::Type::Module)