class Byebug::MethodSigCommand
Implements byebug’s ‘method sig’ command.
def execute
def execute obj = debug_eval('method(:%s)' % @match[1]) if obj.is_a?(Method) begin print "%s\n", obj.signature.to_s rescue errmsg("Can't get signature for '#{@match[1]}'\n") end else errmsg("Can't make method out of '#{@match[1]}'\n") end end
def help(cmd)
def help(cmd) %{ m[ethod] sig[nature] <obj>\tshow the signature of a method } end
def help_command
def help_command 'method' end
def regexp
def regexp /^\s*m(?:ethod)?\s+sig(?:nature)?\s+(\S+)\s*$/ end