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(eslint-plugin): support BigInt in restrict-plus-operands rule #310

Merged
merged 3 commits into from Feb 23, 2019
Merged

Conversation

webschik
Copy link
Contributor

@webschik webschik commented Feb 23, 2019

Fixes #309

@j-f1 j-f1 changed the title fix(eslint-plugin): support BigInt in restrict-plus-operands rule (#309) fix(eslint-plugin): support BigInt in restrict-plus-operands rule Feb 23, 2019
column: 11,
},
],
},
Copy link
Contributor

Choose a reason for hiding this comment

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

Can you add tests for var foo = 1n + "1" and var foo = "1" + 1n?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@j-f1 , what do we want to get in these cases, notBigInts or notStrings errors?
Because now they are covered by notStrings check, that's why I haven't added them.

@JamesHenry
Copy link
Member

Nice, thanks @webschik!

@codecov
Copy link

codecov bot commented Feb 23, 2019

Codecov Report

Merging #310 into master will increase coverage by <.01%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master     #310      +/-   ##
==========================================
+ Coverage   97.26%   97.27%   +<.01%     
==========================================
  Files          67       67              
  Lines        2344     2348       +4     
  Branches      334      335       +1     
==========================================
+ Hits         2280     2284       +4     
  Misses         43       43              
  Partials       21       21
Impacted Files Coverage Δ
.../eslint-plugin/src/rules/restrict-plus-operands.ts 96.15% <100%> (+0.69%) ⬆️

@JamesHenry JamesHenry merged commit 9a88363 into typescript-eslint:master Feb 23, 2019
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 21, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[restrict-plus-operands] rule doesn't support bigint
4 participants