Skip to content

Commit

Permalink
prefer alias_method
Browse files Browse the repository at this point in the history
  • Loading branch information
jreidinger committed Jul 14, 2016
1 parent 924533b commit 6d92d34
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions ytools/y2tool/rubocop_yast_style.yml
Expand Up @@ -218,3 +218,15 @@ Style/DoubleNegation:
Performance/RedundantBlockCall:
Enabled: false

# alias method is more convenient method for method aliasing even when in class
# context self scope is not so clear
# see https://github.com/bbatsov/ruby-style-guide#alias-method-lexically
# so force
# class C
# alias_method :a, :b
#
# instead of:
# class C
# alias b a
Style/Alias:
EnforcedStyle: prefer_alias_method

0 comments on commit 6d92d34

Please sign in to comment.