parser_misc Summary: AST Parsed : 109/109 (100.00%) Positive Passed: 109/109 (100.00%) Negative Passed: 222/222 (100.00%) × Cannot assign to 'arguments' in strict mode ╭─[misc/fail/arguments-eval-ambient.ts:2:13] 1 │ export {}; 2 │ declare var arguments: unknown; · ───────── 3 │ declare const eval: unknown; ╰──── note: Modules are always strict mode code × Cannot assign to 'eval' in strict mode ╭─[misc/fail/arguments-eval-ambient.ts:3:15] 2 │ declare var arguments: unknown; 3 │ declare const eval: unknown; · ──── ╰──── note: Modules are always strict mode code × Cannot assign to 'arguments' in strict mode ╭─[misc/fail/arguments-eval.ts:1:10] 1 │ function arguments() {} · ───────── 2 │ function eval() {} ╰──── note: Modules are always strict mode code × Cannot assign to 'eval' in strict mode ╭─[misc/fail/arguments-eval.ts:2:10] 1 │ function arguments() {} 2 │ function eval() {} · ──── 3 │ ╰──── note: Modules are always strict mode code × Cannot assign to 'arguments' in strict mode ╭─[misc/fail/arguments-eval.ts:4:16] 3 │ 4 │ function foo({ arguments }) {} · ───────── 5 │ function foo2([arguments]) {} ╰──── note: Modules are always strict mode code × Cannot assign to 'arguments' in strict mode ╭─[misc/fail/arguments-eval.ts:5:16] 4 │ function foo({ arguments }) {} 5 │ function foo2([arguments]) {} · ───────── 6 │ function foo3({ eval }) {} ╰──── note: Modules are always strict mode code × Cannot assign to 'eval' in strict mode ╭─[misc/fail/arguments-eval.ts:6:17] 5 │ function foo2([arguments]) {} 6 │ function foo3({ eval }) {} · ──── 7 │ function foo4([eval]) {} ╰──── note: Modules are always strict mode code × Cannot assign to 'eval' in strict mode ╭─[misc/fail/arguments-eval.ts:7:16] 6 │ function foo3({ eval }) {} 7 │ function foo4([eval]) {} · ──── 8 │ declare function foo5({ arguments }: { arguments: number }): void; ╰──── note: Modules are always strict mode code × Cannot assign to 'arguments' in strict mode ╭─[misc/fail/arguments-eval.ts:8:25] 7 │ function foo4([eval]) {} 8 │ declare function foo5({ arguments }: { arguments: number }): void; · ───────── 9 │ declare function foo6([eval]: [number]): void; ╰──── note: Modules are always strict mode code × Cannot assign to 'eval' in strict mode ╭─[misc/fail/arguments-eval.ts:9:24] 8 │ declare function foo5({ arguments }: { arguments: number }): void; 9 │ declare function foo6([eval]: [number]): void; · ──── 10 │ declare function foo7([arguments = 0]: [number?]): void; ╰──── note: Modules are always strict mode code × Cannot assign to 'arguments' in strict mode ╭─[misc/fail/arguments-eval.ts:10:24] 9 │ declare function foo6([eval]: [number]): void; 10 │ declare function foo7([arguments = 0]: [number?]): void; · ───────── 11 │ declare function foo8({ ...arguments }: object): void; ╰──── note: Modules are always strict mode code × Cannot assign to 'arguments' in strict mode ╭─[misc/fail/arguments-eval.ts:11:28] 10 │ declare function foo7([arguments = 0]: [number?]): void; 11 │ declare function foo8({ ...arguments }: object): void; · ───────── 12 │ declare function foo9([...eval]: unknown[]): void; ╰──── note: Modules are always strict mode code × Cannot assign to 'eval' in strict mode ╭─[misc/fail/arguments-eval.ts:12:27] 11 │ declare function foo8({ ...arguments }: object): void; 12 │ declare function foo9([...eval]: unknown[]): void; · ──── 13 │ declare class C { ╰──── note: Modules are always strict mode code × Cannot assign to 'eval' in strict mode ╭─[misc/fail/arguments-eval.ts:14:12] 13 │ declare class C { 14 │ method({ eval }: { eval: number }): void; · ──── 15 │ constructor([arguments]: [number]); ╰──── note: Classes are always strict mode code × Cannot assign to 'arguments' in strict mode ╭─[misc/fail/arguments-eval.ts:15:16] 14 │ method({ eval }: { eval: number }): void; 15 │ constructor([arguments]: [number]); · ───────── 16 │ } ╰──── note: Classes are always strict mode code × Only a single declaration is allowed in a `for...in` statement ╭─[misc/fail/arrow-block-body-in-context.js:1:6] 1 │ for (var f = () => {}, value = a in b;;); · ─────────────────────────── ╰──── × Expected `)` but found `;` ╭─[misc/fail/arrow-block-body-in-context.js:1:38] 1 │ for (var f = () => {}, value = a in b;;); · ┬ ┬ · │ ╰── `)` expected · ╰── Opened here ╰──── × Expected `)` but found `;` ╭─[misc/fail/arrow-expression-body-in.js:1:26] 1 │ for (var f = () => a in b;;); · ┬ ┬ · │ ╰── `)` expected · ╰── Opened here ╰──── × Illegal break statement ╭─[misc/fail/arrow-function-jumps.js:1:25] 1 │ while (true) { (() => { break; }); } · ────── 2 │ ╰──── help: A `break` statement can only be used within an enclosing iteration or switch statement. × Jump target cannot cross function boundary. ╭─[misc/fail/arrow-function-jumps.js:3:38] 2 │ 3 │ outer: while (true) { (() => { break outer; }); } · ───── 4 │ ╰──── × Illegal continue statement: no surrounding iteration statement ╭─[misc/fail/arrow-function-jumps.js:5:25] 4 │ 5 │ while (true) { (() => { continue; }); } · ───────── 6 │ ╰──── help: A `continue` statement can only be used within an enclosing `for`, `while` or `do while` × Jump target cannot cross function boundary. ╭─[misc/fail/arrow-function-jumps.js:7:41] 6 │ 7 │ outer: while (true) { (() => { continue outer; }); } · ───── ╰──── × 'async' modifier cannot be used here. ╭─[misc/fail/async-field.js:1:11] 1 │ class C { async x; } · ───── ╰──── × 'async' modifier cannot be used here. ╭─[misc/fail/async-field.ts:1:11] 1 │ class C { async x; } · ───── ╰──── × `await` is only allowed within async functions and at the top levels of modules ╭─[misc/fail/auto-accessor-initializer-await.js:3:18] 2 │ class C { 3 │ accessor x = await 1; · ───── 4 │ } ╰──── help: Either remove this `await` or add the `async` keyword to the enclosing function × A 'yield' expression is only allowed in a generator body. ╭─[misc/fail/auto-accessor-initializer-yield.js:3:18] 2 │ class C { 3 │ accessor x = yield 1; · ───── 4 │ } ╰──── help: Either remove this `yield` or change the enclosing function to a generator function (`function*`) × Cannot use await in class static initialization block ╭─[misc/fail/await-expr-in-block-in-class-static-block.mjs:4:7] 3 │ { 4 │ await foo; · ───── 5 │ } ╰──── × `await` is only allowed within async functions and at the top levels of modules ╭─[misc/fail/await-using-context.js:2:3] 1 │ function f() { 2 │ await using x = null; · ───── 3 │ for (await using y = null; ; ) {} ╰──── help: Either remove this `await` or add the `async` keyword to the enclosing function × `await` is only allowed within async functions and at the top levels of modules ╭─[misc/fail/await-using-context.js:3:8] 2 │ await using x = null; 3 │ for (await using y = null; ; ) {} · ───── 4 │ for (await using z of []) {} ╰──── help: Either remove this `await` or add the `async` keyword to the enclosing function × `await` is only allowed within async functions and at the top levels of modules ╭─[misc/fail/await-using-context.js:4:8] 3 │ for (await using y = null; ; ) {} 4 │ for (await using z of []) {} · ───── 5 │ } ╰──── help: Either remove this `await` or add the `async` keyword to the enclosing function × `await` is only allowed within async functions and at the top levels of modules ╭─[misc/fail/await-using-context.js:8:3] 7 │ function* g() { 8 │ await using x = null; · ───── 9 │ for (await using y = null; ; ) {} ╰──── help: Either remove this `await` or add the `async` keyword to the enclosing function × `await` is only allowed within async functions and at the top levels of modules ╭─[misc/fail/await-using-context.js:9:8] 8 │ await using x = null; 9 │ for (await using y = null; ; ) {} · ───── 10 │ for (await using z of []) {} ╰──── help: Either remove this `await` or add the `async` keyword to the enclosing function × `await` is only allowed within async functions and at the top levels of modules ╭─[misc/fail/await-using-context.js:10:8] 9 │ for (await using y = null; ; ) {} 10 │ for (await using z of []) {} · ───── 11 │ } ╰──── help: Either remove this `await` or add the `async` keyword to the enclosing function × Expected `;` but found `,` ╭─[misc/fail/class-field-comma-expression.js:1:16] 1 │ class C { x = a,b } · ┬ · ╰── `;` expected ╰──── × Logical expressions and coalesce expressions cannot be mixed ╭─[misc/fail/coalesce-partial-parens-final-left-and.js:1:1] 1 │ a && b ?? (c); · ───────────── ╰──── help: Wrap either expression by parentheses × Logical expressions and coalesce expressions cannot be mixed ╭─[misc/fail/coalesce-partial-parens-final-left-or.js:1:1] 1 │ a || b ?? (c); · ───────────── ╰──── help: Wrap either expression by parentheses × Logical expressions and coalesce expressions cannot be mixed ╭─[misc/fail/coalesce-partial-parens-final-right-and.js:1:1] 1 │ a ?? b && (c); · ───────────── ╰──── help: Wrap either expression by parentheses × Logical expressions and coalesce expressions cannot be mixed ╭─[misc/fail/coalesce-partial-parens-final-right-or.js:1:1] 1 │ a ?? b || (c); · ───────────── ╰──── help: Wrap either expression by parentheses × Logical expressions and coalesce expressions cannot be mixed ╭─[misc/fail/coalesce-partial-parens-left-and.js:1:1] 1 │ (a) && b ?? c; · ───────────── ╰──── help: Wrap either expression by parentheses × Logical expressions and coalesce expressions cannot be mixed ╭─[misc/fail/coalesce-partial-parens-left-or.js:1:1] 1 │ (a) || b ?? c; · ───────────── ╰──── help: Wrap either expression by parentheses × Logical expressions and coalesce expressions cannot be mixed ╭─[misc/fail/coalesce-partial-parens-right-and.js:1:1] 1 │ a ?? (b) && c; · ───────────── ╰──── help: Wrap either expression by parentheses × Logical expressions and coalesce expressions cannot be mixed ╭─[misc/fail/coalesce-partial-parens-right-or.js:1:1] 1 │ a ?? (b) || c; · ───────────── ╰──── help: Wrap either expression by parentheses × Cannot use export statement outside a module ╭─[misc/fail/commonjs-export-statement.cjs:2:1] 1 │ // CommonJS does NOT allow export statements (use module.exports instead) 2 │ export const foo = 1; · ────── ╰──── × Unexpected import.meta expression ╭─[misc/fail/commonjs-import-meta.cjs:2:1] 1 │ // CommonJS does NOT allow import.meta (only ES modules do) 2 │ import.meta; · ─────────── ╰──── help: import.meta is only allowed in module code × Cannot use import statement outside a module ╭─[misc/fail/commonjs-import-statement.cjs:2:1] 1 │ // CommonJS does NOT allow import statements (use require instead) 2 │ import foo from 'foo'; · ────── ╰──── × `await` is only allowed within async functions and at the top levels of modules ╭─[misc/fail/commonjs-top-level-await.cjs:2:1] 1 │ // CommonJS does NOT allow top-level await (only ES modules do) 2 │ await Promise.resolve(); · ───── ╰──── help: Either remove this `await` or add the `async` keyword to the enclosing function × TS(1093): Type annotation cannot appear on a constructor declaration. ╭─[misc/fail/constructor-overload-return-type.ts:2:18] 1 │ class C { 2 │ constructor(): C; · ─ 3 │ constructor() {} ╰──── × Expected `)` but found `:` ╭─[misc/fail/contextual-binding-lookahead-function-reserved.ts:1:15] 1 │ let fn: (break: number) => void; · ┬ · ╰── `)` expected ╰──── × Cannot use `yield` as an identifier in a generator context ╭─[misc/fail/contextual-binding-lookahead-index-context.ts:2:18] 1 │ function* generatorInterface() { 2 │ interface I { [yield: string]: unknown } · ───── 3 │ } ╰──── × Cannot use `yield` as an identifier in a generator context ╭─[misc/fail/contextual-binding-lookahead-index-context.ts:5:14] 4 │ function* generatorClass() { 5 │ class C { [yield: string]: unknown } · ───── 6 │ } ╰──── × Cannot use `await` as an identifier in an async context ╭─[misc/fail/contextual-binding-lookahead-index-context.ts:8:14] 7 │ async function asyncClass() { 8 │ class C { [await: string]: unknown } · ───── 9 │ } ╰──── × Unexpected token ╭─[misc/fail/contextual-binding-lookahead-index-modifier.ts:1:23] 1 │ interface I { [public await: string]: unknown } · ───── ╰──── × Unexpected token ╭─[misc/fail/contextual-binding-lookahead-index-reserved.ts:1:16] 1 │ interface I { [break: string]: unknown } · ───── ╰──── × A `continue` statement can only jump to a label of an enclosing `for`, `while` or `do while` statement. ╭─[misc/fail/continue-label-chain-non-iteration.js:1:1] 1 │ a: b: { · ┬ · ╰── This is an non-iteration statement 2 │ continue a; · ┬ · ╰── for this label 3 │ } ╰──── × Encountered diff marker ╭─[misc/fail/diff-markers.js:10:1] 9 │ function test() { 10 │ <<<<<<< HEAD · ───┬─── · ╰── between this marker and `=======` is the code that we're merging into 11 │ const x = 1; 12 │ ======= · ───┬─── · ╰── between this marker and `>>>>>>>` is the incoming code 13 │ const y = 2; 14 │ >>>>>>> branch · ───┬─── · ╰── this marker concludes the conflict region 15 │ return x; ╰──── help: Conflict markers indicate that a merge was started but could not be completed due to merge conflicts. To resolve a conflict, keep only the code you want and then delete the lines containing conflict markers. If you're having merge conflicts after pulling new code, the top section is the code you already had and the bottom section is the remote code. If you're in the middle of a rebase, the top section is the code being rebased onto and the bottom section is the code coming from the current commit being rebased. If you have nested conflicts, resolve the outermost conflict first. × Identifier `#x` has already been declared ╭─[misc/fail/duplicate-private-declarations.js:1:24] 1 │ class DuplicateField { #x; x; #x; } · ─┬ ─┬ · │ ╰── It can not be redeclared here · ╰── `#x` has already been declared here 2 │ ╰──── × Identifier `#x` has already been declared ╭─[misc/fail/duplicate-private-declarations.js:3:29] 2 │ 3 │ class DuplicateGetter { get #x() {} set #x(value) {} get #x() {} } · ─┬ ─┬ · │ ╰── It can not be redeclared here · ╰── `#x` has already been declared here 4 │ ╰──── × Identifier `#x` has already been declared ╭─[misc/fail/duplicate-private-declarations.js:5:29] 4 │ 5 │ class DuplicateSetter { set #x(value) {} get #x() {} set #x(value) {} } · ─┬ ─┬ · │ ╰── It can not be redeclared here · ╰── `#x` has already been declared here ╰──── × '0'-prefixed octal literals and octal escape sequences are deprecated ╭─[misc/fail/escape-00.js:1:25] 1 │ export const escape00 = "\00"; · ───── ╰──── help: for octal literals use the '0o' prefix instead × Keywords cannot contain escape characters ╭─[misc/fail/escaped-import-phase.js:1:8] 1 │ import s\u006furce wasm from "m"; · ─────────── 2 │ import d\u0065fer * as ns from "m"; ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-import-phase.js:2:8] 1 │ import s\u006furce wasm from "m"; 2 │ import d\u0065fer * as ns from "m"; · ────────── 3 │ import source fr\u006fm "m"; ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-import-phase.js:3:15] 2 │ import d\u0065fer * as ns from "m"; 3 │ import source fr\u006fm "m"; · ───────── 4 │ import s\u006furce from from "m"; ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-import-phase.js:4:8] 3 │ import source fr\u006fm "m"; 4 │ import s\u006furce from from "m"; · ─────────── ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-type-import.ts:1:8] 1 │ import t\u0079pe Foo = require("m"); · ───────── 2 │ import t\u0079pe { x } from "m"; ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-type-import.ts:2:8] 1 │ import t\u0079pe Foo = require("m"); 2 │ import t\u0079pe { x } from "m"; · ───────── 3 │ import t\u0079pe * as ns from "m"; ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-type-import.ts:3:8] 2 │ import t\u0079pe { x } from "m"; 3 │ import t\u0079pe * as ns from "m"; · ───────── 4 │ import { t\u0079pe Bar } from "m"; ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-type-import.ts:4:10] 3 │ import t\u0079pe * as ns from "m"; 4 │ import { t\u0079pe Bar } from "m"; · ───────── 5 │ import t\u0079pe fr\u006fm "m"; ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-type-import.ts:5:18] 4 │ import { t\u0079pe Bar } from "m"; 5 │ import t\u0079pe fr\u006fm "m"; · ───────── ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-type-specifier.ts:1:10] 1 │ import { t\u0079pe as as x } from "m"; · ───────── 2 │ export { t\u0079pe Foo }; ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-type-specifier.ts:2:10] 1 │ import { t\u0079pe as as x } from "m"; 2 │ export { t\u0079pe Foo }; · ───────── 3 │ export { t\u0079pe as }; ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-type-specifier.ts:3:10] 2 │ export { t\u0079pe Foo }; 3 │ export { t\u0079pe as }; · ───────── 4 │ export { t\u0079pe as as x }; ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-type-specifier.ts:4:10] 3 │ export { t\u0079pe as }; 4 │ export { t\u0079pe as as x }; · ───────── 5 │ export { t\u0079pe Foo } from "m"; ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-type-specifier.ts:5:10] 4 │ export { t\u0079pe as as x }; 5 │ export { t\u0079pe Foo } from "m"; · ───────── 6 │ export { t\u0079pe as as x } from "m"; ╰──── × Keywords cannot contain escape characters ╭─[misc/fail/escaped-type-specifier.ts:6:10] 5 │ export { t\u0079pe Foo } from "m"; 6 │ export { t\u0079pe as as x } from "m"; · ───────── ╰──── × A unary expression with the '-' operator cannot be used as the left operand of an exponentiation expression ╭─[misc/fail/exponentiation-left-operands.ts:1:1] 1 │ -value ** 2; · ────── 2 │ await value ** 2; ╰──── help: Wrap the unary expression in parentheses to make the precedence explicit × A unary expression with the 'await' operator cannot be used as the left operand of an exponentiation expression ╭─[misc/fail/exponentiation-left-operands.ts:2:1] 1 │ -value ** 2; 2 │ await value ** 2; · ─────────── 3 │ value ** 2; ╰──── help: Wrap the unary expression in parentheses to make the precedence explicit × A type assertion cannot be used as the left operand of an exponentiation expression ╭─[misc/fail/exponentiation-left-operands.ts:3:1] 2 │ await value ** 2; 3 │ value ** 2; · ───────────── ╰──── help: Wrap the type assertion in parentheses to make the precedence explicit × TS(2309): An export assignment cannot be used in a module with other exported elements ╭─[misc/fail/export-equal-with-normal-export.ts:4:1] 3 │ 4 │ export = 3; · ─────────── 5 │ export = 4; ╰──── help: If you want to use `export =`, remove other `export`s and put all of them to the right hand value of `export =`. If you want to use `export`s, remove `export =` statement. × TS(2309): An export assignment cannot be used in a module with other exported elements ╭─[misc/fail/export-equal-with-normal-export.ts:5:1] 4 │ export = 3; 5 │ export = 4; · ─────────── ╰──── help: If you want to use `export =`, remove other `export`s and put all of them to the right hand value of `export =`. If you want to use `export`s, remove `export =` statement. × Unexpected token ╭─[misc/fail/export-from-missing-source-eof.js:2:1] 1 │ export {} from ╰──── × Unexpected token ╭─[misc/fail/export-from-missing-source-newline.js:2:1] 1 │ export {} from 2 │ foo(); · ─── ╰──── × Unexpected token ╭─[misc/fail/export-from-missing-source-semicolon.js:1:15] 1 │ export {} from; · ─ ╰──── × Invalid escape sequence ╭─[misc/fail/export-from-prior-lexer-error.js:1:11] 1 │ export { "\xG" as foo } from · ── ╰──── × Unterminated multiline comment ╭─[misc/fail/export-from-unterminated-comment.js:1:16] 1 │ export {} from /* · ─── ╰──── × Unterminated string ╭─[misc/fail/export-from-unterminated-source.js:1:16] 1 │ export {} from " · ── ╰──── × The left-hand side of a for...in statement cannot be an await using declaration. ╭─[misc/fail/for-await-using-in-initializer.js:2:8] 1 │ async function f() { 2 │ for (await using x = a in b;;); · ───────────────── 3 │ } ╰──── help: Did you mean to use a for...of statement? × Expected `)` but found `;` ╭─[misc/fail/for-await-using-in-initializer.js:2:30] 1 │ async function f() { 2 │ for (await using x = a in b;;); · ┬ ┬ · │ ╰── `)` expected · ╰── Opened here 3 │ } ╰──── × Expected `;` but found `Identifier` ╭─[misc/fail/for-escaped-let-declaration.cjs:1:15] 1 │ for (l\u0065t x = 0;;); · ┬ · ╰── `;` expected ╰──── × Expected `;` but found `Identifier` ╭─[misc/fail/for-in-escaped-let-declaration.cjs:1:15] 1 │ for (l\u0065t x in {}); · ┬ · ╰── `;` expected ╰──── × Expected `;` but found `Identifier` ╭─[misc/fail/for-of-escaped-let-declaration.cjs:1:15] 1 │ for (l\u0065t x of []); · ┬ · ╰── `;` expected ╰──── × The left-hand side of a for...in statement cannot be an using declaration. ╭─[misc/fail/for-using-in-initializer.js:1:6] 1 │ for (using x = a in b;;); · ─────────── ╰──── help: Did you mean to use a for...of statement? × Expected `)` but found `;` ╭─[misc/fail/for-using-in-initializer.js:1:22] 1 │ for (using x = a in b;;); · ┬ ┬ · │ ╰── `)` expected · ╰── Opened here ╰──── × A 'get' accessor must not have any formal parameters. ╭─[misc/fail/getter-rest-parameter.ts:1:16] 1 │ class C { get x(...args) {} } · ───────── 2 │ ({ get x(...args) {} }); ╰──── help: Remove these parameters here × A 'get' accessor must not have any formal parameters. ╭─[misc/fail/getter-rest-parameter.ts:2:9] 1 │ class C { get x(...args) {} } 2 │ ({ get x(...args) {} }); · ───────── 3 │ interface I { get x(...args: any[]): string } ╰──── help: Remove these parameters here × A 'get' accessor must not have any formal parameters. ╭─[misc/fail/getter-rest-parameter.ts:3:20] 2 │ ({ get x(...args) {} }); 3 │ interface I { get x(...args: any[]): string } · ──────────────── 4 │ type T = { get x(...args: any[]): string }; ╰──── help: Remove these parameters here × A 'get' accessor must not have any formal parameters. ╭─[misc/fail/getter-rest-parameter.ts:4:17] 3 │ interface I { get x(...args: any[]): string } 4 │ type T = { get x(...args: any[]): string }; · ──────────────── ╰──── help: Remove these parameters here × HTML comments are not allowed in modules ╭─[misc/fail/html-comment-in-module.mjs:1:1] 1 │