-
-
Notifications
You must be signed in to change notification settings - Fork 82
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
Retire Performance/Casecmp
cop
#240
Comments
parkerfinch
added a commit
to parkerfinch/rubocop-performance
that referenced
this issue
May 5, 2021
This cop suggests an incorrect fix when code involves non-ASCII characters. Disabling it by default makes this risky behavior opt-in rather than opt-out.
parkerfinch
added a commit
to parkerfinch/rubocop-performance
that referenced
this issue
May 5, 2021
This cop suggests an incorrect fix when code involves non-ASCII characters. Disabling it by default makes this risky behavior opt-in rather than opt-out.
There is another issue with the |
Another issue with this cop: Both lines above return the same offence message. Checkout lines:
|
koic
added a commit
that referenced
this issue
Apr 1, 2022
patrickm53
pushed a commit
to patrickm53/performance-develop-rubyonrails
that referenced
this issue
Sep 23, 2022
richardstewart0213
added a commit
to richardstewart0213/performance-build-Performance-optimization-analysis-
that referenced
this issue
Nov 4, 2022
Cute0110
added a commit
to Cute0110/Rubocop-Performance
that referenced
this issue
Sep 28, 2023
SerhiiMisiura
added a commit
to SerhiiMisiura/Rubocop-Performance
that referenced
this issue
Oct 5, 2023
koic
added a commit
that referenced
this issue
Feb 17, 2024
[Fix #240] Disable `Performance/Casecmp` cop
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This follows up on the ideas generated in #100.
It is confusing to have this cop enabled. Even when the autocorrection is marked as unsafe, the cop still directs people to use
casecmp(...).zero?
, which is incorrect in non-ascii use cases.This issue pairs with rubocop/rubocop#9753, where I'm hoping we can create a Linting cop to suggest using
casecmp?
.The text was updated successfully, but these errors were encountered: