require-atomic-updates incorrectly considers out-of-scope variables #14045
Labels
archived due to age
This issue has been archived; please open a new issue for any further discussion
bug
ESLint is working incorrectly
triage
An ESLint team member will look at this issue soon
Tell us about your environment
What parser (default,
@babel/eslint-parser
,@typescript-eslint/parser
, etc.) are you using?default
Please show your full configuration:
Configuration
What did you do? Please include the actual source code causing the issue, as well as the command that you used to run ESLint.
What did you expect to happen?
No warning to be produced, since there is no asynchronicity involved in the second loop.
What actually happened? Please include the actual, raw output from ESLint.
For comparison, the following code – with only the name of the iteration variable changed – produces no warnings.
Are you willing to submit a pull request to fix this bug?
no
The text was updated successfully, but these errors were encountered: