Logical nullish assignment together with nullish coalescing produces false positive for "use before assignment" #41153
Labels
Bug
A bug in TypeScript
Fix Available
A PR has been opened for this issue
Help Wanted
You can do this
Milestone
TypeScript Version: 4.1.0-dev.20201015
Search Terms: logical nullish assignment use before assigned
Code
Expected behavior:
No error in the last line
Actual behavior:
Error: x is used before being assigned
Playground Link: Playground
Related Issues:
The text was updated successfully, but these errors were encountered: