Correct spurious syntax errors

Prior to this commit, two tests for specific early errors also included
syntactically invalid `const` declarations. Implementations which
produced the expected syntax error due to these invalid declarations
would pass the tests regardless of whether they produced the early
errors that the tests were written to verify.

Correct the `const` declarations so that the tests verify the parsing
rule that they were designed to verify.
This commit is contained in:
Mike Pennisi 2022-06-16 22:28:25 -04:00 committed by Ms2ger
parent 13c1b3b546
commit 74de3d1d32
2 changed files with 2 additions and 2 deletions

View File

@ -15,4 +15,4 @@ negative:
$DONOTEVALUATE();
let x;
const x;
const x = 0;

View File

@ -15,4 +15,4 @@ info: |
$DONOTEVALUATE();
for (const x; false; ) label1: label2: function f() {}
for (const x = 0; false; ) label1: label2: function f() {}