Skip to content

Conversation

@phaux
Copy link
Contributor

@phaux phaux commented Oct 9, 2021

Fixes #3644

@typescript-eslint
Copy link
Contributor

Thanks for the PR, @phaux!

typescript-eslint is a 100% community driven project, and we are incredibly grateful that you are contributing to that community.

The core maintainers work on this in their personal time, so please understand that it may not be possible for them to review your work immediately.

Thanks again!


🙏 Please, if you or your company is finding typescript-eslint valuable, help us sustain the project by sponsoring it transparently on https://opencollective.com/typescript-eslint. As a thank you, your profile/company logo will be added to our main README which receives thousands of unique visitors per day.

@codecov
Copy link

codecov bot commented Oct 9, 2021

Codecov Report

Merging #3981 (66bcc69) into master (9aea46a) will increase coverage by 0.67%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master    #3981      +/-   ##
==========================================
+ Coverage   92.83%   93.50%   +0.67%     
==========================================
  Files         192      151      -41     
  Lines        8760     8143     -617     
  Branches     2690     2585     -105     
==========================================
- Hits         8132     7614     -518     
+ Misses        243      167      -76     
+ Partials      385      362      -23     
Flag Coverage Δ
unittest 93.50% <100.00%> (+0.67%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...int-plugin/src/rules/strict-boolean-expressions.ts 98.78% <100.00%> (ø)
packages/eslint-plugin-tslint/src/rules/config.ts
packages/experimental-utils/src/ts-eslint/index.ts
packages/experimental-utils/src/ast-utils/misc.ts
.../experimental-utils/src/ts-eslint/ParserOptions.ts
...xperimental-utils/src/ts-eslint-scope/Reference.ts
...l-utils/src/ast-utils/eslint-utils/astUtilities.ts
...mental-utils/src/ts-eslint-scope/PatternVisitor.ts
packages/eslint-plugin-tslint/src/custom-linter.ts
...-internal/src/rules/no-typescript-estree-import.ts
... and 32 more

@nx-cloud
Copy link

nx-cloud bot commented Oct 9, 2021

Copy link
Member

@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

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

Super, thanks @phaux! 🚀

}),

// any in boolean context
// TODO: when `T` is not `extends any` then the error is `conditionErrorObject` (says it's always truthy, which is false)
Copy link
Member

Choose a reason for hiding this comment

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

Haha, looks like the attached issue was already known at a point in time!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yup, but I had no idea how to fix it until now and just assumed it's a bug in TS

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[strict-boolean-expressions] False negative for generic parameters

3 participants