mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-08-29 10:48:39 +09:00
Report the error for uninitialized const-declaration in for(;;) loop
head using an explicit offset.
This commit is contained in:
parent
166a9654a8
commit
ade86b0f20
1 changed files with 1 additions and 1 deletions
|
|
@ -4577,7 +4577,7 @@ Parser<ParseHandler>::declarationName(Node decl, DeclarationKind declKind, Token
|
|||
// Normal const declarations, and const declarations in for(;;)
|
||||
// heads, must be initialized.
|
||||
if (declKind == DeclarationKind::Const) {
|
||||
reportWithNode(ParseError, false, binding, JSMSG_BAD_CONST_DECL);
|
||||
errorAt(namePos.begin, JSMSG_BAD_CONST_DECL);
|
||||
return null();
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue