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

Default Style/TrivialAccessors to match names exactly #1673

Closed
marxarelli opened this issue Feb 23, 2015 · 1 comment
Closed

Default Style/TrivialAccessors to match names exactly #1673

marxarelli opened this issue Feb 23, 2015 · 1 comment

Comments

@marxarelli
Copy link
Contributor

The default behavior of Style/TrivialAccessors is quite a bit more strict than the style guide rule. I suggest defaulting ExactNameMatch to true to improve the rule's style guide congruency.

marxarelli added a commit to wikimedia/mediawiki-selenium that referenced this issue Feb 23, 2015
The `Style/TrivialAccessors` rule matches method names which are
different from their exposed instance variable names, effectively
disallowing some necessary method implementations. Configuring the rule
to use exact matching makes it more congruent with the style guide rule.

An upstream issue has been opened to make this the default.
rubocop/rubocop#1673

Change-Id: I90dfd2114e9c47e2045bfa131db3654e0bc3d783
@bbatsov
Copy link
Collaborator

bbatsov commented Feb 24, 2015

The default behavior of Style/TrivialAccessors is quite a bit more strict than the style guide rule. I suggest defaulting ExactNameMatch to true to improve the rule's style guide congruency.

On the other hand the current default reveals "hidden" accessors, which is not a bad thing IMO.

@bbatsov bbatsov closed this as completed in 5910e21 Apr 5, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants