Trailing comma after rest - The final fix (#10491)
* [parser] Track trailing commas in extras instead of state * Update existing tests * Update test262 whitelist * Improve error message and location * nit * Use lookaheadCharCode
This commit is contained in:
@@ -1105,6 +1105,7 @@ export default class StatementParser extends ExpressionParser {
|
||||
this.expect(tt.parenL);
|
||||
node.params = this.parseBindingList(
|
||||
tt.parenR,
|
||||
charCodes.rightParenthesis,
|
||||
/* allowEmpty */ false,
|
||||
allowModifiers,
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user