Re-enable Style/MethodCallWithoutArgsParentheses
Description of the proposal
Renable the Style/MethodCallWithoutArgsParentheses
cop.
https://rubocop.readthedocs.io/en/latest/cops_style/#stylemethodcallwithoutargsparentheses
# bad
object.some_method()
# good
object.some_method
Nearly all of my experience programming comes from languages which require parentheses in order to invoke a method call (C, C++, Java, Javascript, Go, etc). Doing this is second nature.
This means that when submit code for review, the reviewer will inevitably request that I remove some ()
on method calls.
This should be automated. I'm not sure why this isn't picked up by Rubocop at present, but having it so would save me extra rounds of review.
If I change the configuration, there are 31 offences of this rule on master, but these can all be autocorrect.
$ rubocop --only "Style/MethodCallWithoutArgsParentheses" --auto-correct
...
7901 files inspected, 31 offenses detected, 31 offenses corrected
-
Mention the proposal in the next backend weekly call and the #backend channel to encourage contribution -
Proceed with the proposal once 50% of the maintainers have weighed in, and 80% of the votes are 👍 -
Once approved, mention it again in the next backend weekly call and the #backend channel
Maintainer Voting
Maintainer | Ayes to the right | Nays to the left |
---|---|---|
@ayufan | ||
@dbalexandre | ||
@DouweM | ||
@dzaporozhets | ||
@godfat | ||
@grzesiek | ||
@nick.thomas | ||
@rspeicher | ||
@rymai | ||
@smcgivern | ||
@stanhu |
Award emoji list: https://gitlab.com/api/v4/projects/gitlab-org%2fgitlab-ce/issues/56795/award_emoji