rubocop: In-line disables of Naming/MemoizedInstanceVariableName
This commit is contained in:
parent
d84d157aaa
commit
6797f30bbf
@ -323,11 +323,6 @@ Lint/DuplicateBranch:
|
|||||||
- "/**/{Formula,Casks}/*.rb"
|
- "/**/{Formula,Casks}/*.rb"
|
||||||
- "**/{Formula,Casks}/*.rb"
|
- "**/{Formula,Casks}/*.rb"
|
||||||
|
|
||||||
# needed for lazy_object magic
|
|
||||||
Naming/MemoizedInstanceVariableName:
|
|
||||||
Exclude:
|
|
||||||
- "Homebrew/lazy_object.rb"
|
|
||||||
|
|
||||||
# useful for metaprogramming in RSpec
|
# useful for metaprogramming in RSpec
|
||||||
Lint/ConstantDefinitionInBlock:
|
Lint/ConstantDefinitionInBlock:
|
||||||
Exclude:
|
Exclude:
|
||||||
|
|||||||
@ -10,9 +10,11 @@ class LazyObject < Delegator
|
|||||||
end
|
end
|
||||||
|
|
||||||
def __getobj__
|
def __getobj__
|
||||||
|
# rubocop:disable Naming/MemoizedInstanceVariableName
|
||||||
return @__delegate__ if defined?(@__delegate__)
|
return @__delegate__ if defined?(@__delegate__)
|
||||||
|
|
||||||
@__delegate__ = @__callable__.call
|
@__delegate__ = @__callable__.call
|
||||||
|
# rubocop:enable Naming/MemoizedInstanceVariableName
|
||||||
end
|
end
|
||||||
|
|
||||||
def __setobj__(callable)
|
def __setobj__(callable)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user