Skip to content
This repository has been archived by the owner on Mar 25, 2021. It is now read-only.

no-unused-variable: don't crash at destructuring #3058

Merged
merged 1 commit into from Aug 2, 2017
Merged

no-unused-variable: don't crash at destructuring #3058

merged 1 commit into from Aug 2, 2017

Conversation

ajafff
Copy link
Contributor

@ajafff ajafff commented Jul 19, 2017

PR checklist

Overview of change:

Avoid typescript crash when trying to get type of destructured variable declaration.
Also avoid walking the AST multiple times when --declaration is not enabled. That should result in better performance and fewer false negatives.

[bugfix] no-unused-variable fixed crash when using destructuring
Fixes: #2876
Fixes: #3001

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

CHANGELOG.md entry:

Avoid typescript crash when trying to get type of destructured variable declaration.
Also avoid walking the AST multiple times when `--declaration` is not enabled. That should result in better performance and fewer false negatives.

[bugfix] `no-unused-variable` fixed crash when using destructuring
Fixes: #2876
Fixes: #3001
@pelotom
Copy link

pelotom commented Aug 7, 2017

Hi, we would love to get this fix. Any idea when we can expect it to make its way into a release?

@adidahiya
Copy link
Contributor

@pelotom we'll try to release v5.6.0 this week. in the meantime you can grab the latest commit from master

HyphnKnight pushed a commit to HyphnKnight/tslint that referenced this pull request Apr 9, 2018
Avoid typescript crash when trying to get type of destructured variable declaration.
Also avoid walking the AST multiple times when `--declaration` is not enabled. That should result in better performance and fewer false negatives.

[bugfix] `no-unused-variable` fixed crash when using destructuring
Fixes: palantir#2876
Fixes: palantir#3001
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
3 participants