Class: Rubinius::Debugger::Command::SetFrame
- Inherits:
-
Rubinius::Debugger::Command
- Object
- Rubinius::Debugger::Command
- Rubinius::Debugger::Command::SetFrame
- 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
425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 |
# File 'lib/rubinius/debugger/commands.rb', line 425 def run(args) unless m = /(\d+)/.match(args) error "Invalid frame number: #{args}" return end num = m[1].to_i if num >= @debugger.locations.size error "Frame #{num} too big" return end @debugger.set_frame(num) info current_frame.describe @debugger.show_code end |