Class: RuboCop::Cop::Memosa::MethodDefinition

Inherits:
Base
  • Object
show all
Defined in:
lib/rubocop/cop/memosa.rb

Overview

This cop checks for memoized methods that accept arguments or yield.

Examples:

# bad
def foo; end
memoize :foo

# good
memoize def foo; end

Constant Summary collapse

MSG =

Returns:

  • (String)
"`memoize` should precede a method definition (e.g. `memoize def`)"