Class: Debugger::NextCommand
- Defined in:
- lib/ruby-debug/commands/stepping.rb
Overview
:nodoc
Constant Summary
Constants inherited from Command
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Command
commands, inherited, #initialize, load_commands, #match, method_missing, options
Constructor Details
This class inherits a constructor from Debugger::Command
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Debugger::Command
Class Method Details
.help(cmd) ⇒ Object
21 22 23 24 25 |
# File 'lib/ruby-debug/commands/stepping.rb', line 21 def help(cmd) %{ n[ext][nl] [tf]\tgo over n lines, default is one, go to target frame tf (1-based) } end |
.help_command ⇒ Object
17 18 19 |
# File 'lib/ruby-debug/commands/stepping.rb', line 17 def help_command 'next' end |
Instance Method Details
#execute ⇒ Object
9 10 11 12 13 14 |
# File 'lib/ruby-debug/commands/stepping.rb', line 9 def execute steps = @match[1] ? @match[1].to_i : 1 target_frame = @match[2] ? (@match[2].to_i() -1) : @state.frame_pos @state.context.step_over steps, target_frame @state.proceed end |
#regexp ⇒ Object
5 6 7 |
# File 'lib/ruby-debug/commands/stepping.rb', line 5 def regexp /^\s*n(?:ext)?(?:\s+(\d+))?(?:\s+(\d+))?$/ end |