Files
oxc-project__oxc/tasks/coverage/misc/pass/oxc-24804.ts
Boshen 582805df03 fix(parser): parse unary conditional after satisfies (#24807)
Fixes #24804.

Recognize `!` as a type-start token so `?` after `satisfies` remains the conditional-expression operator instead of being consumed as a JSDoc nullable type.

Validated with `just ready`.

AI-assisted.
2026-07-22 13:22:14 +00:00

4 lines
82 B
TypeScript

const foo = "foo"
const bar = "bar"
foo === "value" satisfies string ? !bar : bar