class UnboundMethod

Public Instance Methods

explicit_receiver() click to toggle source

returns a version of the procedure that takes the receiver (that would otherwise need to be bound with .bind()) as the first argument

# File lib/abstractivator/proc_ext.rb, line 146
def explicit_receiver
  proc do |receiver, *args, &block|
    self.bind(receiver).call(*args, &block)
  end
end