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
Rename Lint/AmbiguousOperatorPrecedence
to Style/ExplicitOperatorPrecedence
#11111
base: master
Are you sure you want to change the base?
Conversation
I'll have to think about this, but I'm open to the suggestion in general. Plus I think we should start focusing our attention on RuboCop 2.0 soon anyways, as a lot of breaking changes have piled up in the backlog. I also think that it's important for to start working on the "cop squads" or however we decide to name them in the end, as I think that allowing people to run some smaller more focused squads will solve much of such issues anyways. |
…recedence` Follow up rubocop#10080 (comment). This PR renames `Lint/AmbiguousOperatorPrecedence` cop from `Style/ExplicitOperatorPrecedence`. The above link comment would make a lot of sense. And other feedback on the issue has also been commented the cop shouldn't be at a particularly high "severity" level like `Lint`. I think it could be considered disabled by default, but this PR moves to `Style` instead of `Lint` anyway. I understand that it shouldn't breaking change until 2.0, but I believe this is worth the breaking change for early adopters using pending cop. As a side note, I think this should not be enforced by source code, as it can be completed in the editor if desired. https://twitter.com/kddnewton/status/1485712576076042241
255a363
to
00b9a33
Compare
What I'm most interested regarding the inheritance approach is if would offences be displayed for both the old and the new cop? It was one of the decision-making factors for |
Ah, Indeed. Redundant warnings can be confusing. I'll take a closer look later. |
Just to avoid any confusion, redundant offences, not warnings.
Contrary to the inheritance approach, |
Yeah. It's offense, not warning. I was using the wrong terminology 😅 |
Follow up #10080 (comment).
This PR renames
Lint/AmbiguousOperatorPrecedence
cop fromStyle/ExplicitOperatorPrecedence
.The above link comment would make a lot of sense. And other feedback on the issue has also been commented the cop shouldn't be at a particularly high "severity" level like
Lint
. I think it could be considered disabled by default, but this PR moves toStyle
instead ofLint
anyway.I understand that it shouldn't breaking change until 2.0, but I believe this is worth the breaking change for early adopters using pending cop.
As a side note, I think this should not be enforced by source code, as it can be completed in the editor if desired.
https://twitter.com/kddnewton/status/1485712576076042241
Before submitting the PR make sure the following are checked:
[Fix #issue-number]
(if the related issue exists).master
(if not - rebase it).bundle exec rake default
. It executes all tests and runs RuboCop on its own code.{change_type}_{change_description}.md
if the new code introduces user-observable changes. See changelog entry format for details.