Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: no-unused-vars updated location to last reference (fixes #13181) #13354

Merged
merged 5 commits into from Jun 1, 2020

Conversation

anikethsaha
Copy link
Member

Prerequisites checklist

What is the purpose of this pull request? (put an "X" next to an item)

[ ] Documentation update
[ ] Bug fix (template)
[ ] New rule (template)
[X] Changes an existing rule (template)
[ ] Add autofixing to a rule
[ ] Add a CLI option
[ ] Add something to the core
[ ] Other, please explain:

What changes did you make? (Give an overview)

fixes #13181
Updated the location for no-unused-vars to report at the last reference of a variable when not being used.

image
image

Is there anything you'd like reviewers to focus on?

Should this be Update instead of Fix ?

@eslint-deprecated eslint-deprecated bot added the triage An ESLint team member will look at this issue soon label May 25, 2020
lib/rules/no-unused-vars.js Outdated Show resolved Hide resolved
@anikethsaha anikethsaha requested a review from nzakas May 26, 2020 07:26
@mdjermanovic mdjermanovic added enhancement This change enhances an existing feature of ESLint evaluating The team will evaluate this issue to decide whether it meets the criteria for inclusion rule Relates to ESLint's core rules and removed triage An ESLint team member will look at this issue soon labels Jun 1, 2020
Copy link
Member

@nzakas nzakas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks!

@nzakas nzakas merged commit 426088c into eslint:master Jun 1, 2020
@anikethsaha anikethsaha deleted the no-unused-vars-reporter-loc-13172 branch June 1, 2020 16:49
@eslint-deprecated eslint-deprecated bot locked and limited conversation to collaborators Nov 29, 2020
@eslint-deprecated eslint-deprecated bot added the archived due to age This issue has been archived; please open a new issue for any further discussion label Nov 29, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
archived due to age This issue has been archived; please open a new issue for any further discussion enhancement This change enhances an existing feature of ESLint evaluating The team will evaluate this issue to decide whether it meets the criteria for inclusion rule Relates to ESLint's core rules
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[no-unused-vars]: reporter should report the last reference instead of declaration
3 participants