Class: Rubinius::Debugger::Command::DeleteBreakpoint

Inherits:
Rubinius::Debugger::Command show all
Defined in:
lib/rubinius/debugger/commands.rb

Instance Method Summary collapse

Methods inherited from Rubinius::Debugger::Command

commands, #current_frame, #current_method, descriptor, ext_help, help, #initialize, #listen, match?, pattern, #run_code, #variables

Methods included from Display

#ask, #crit, #display, #error, #info, #section

Constructor Details

This class inherits a constructor from Rubinius::Debugger::Command

Instance Method Details

#run(args) ⇒ Object



193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
# File 'lib/rubinius/debugger/commands.rb', line 193

def run(args)
  if !args or args.empty?
    error "Please specify which breakpoint by number"
    return
  end

  begin
    i = Integer(args.strip)
  rescue ArgumentError
    error "'#{args}' is not a number"
    return
  end

  @debugger.delete_breakpoint(i)
end