Class: Debugger::NextCommand
- Inherits:
-
Command
- Object
- Command
- Debugger::NextCommand
show all
- Defined in:
- lib/ruby-debug/commands/stepping.rb
Overview
Implements debugger “next” command.
Constant Summary
Constants inherited
from Command
Command::DEF_OPTIONS
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from Command
commands, #find, inherited, #initialize, load_commands, #match, method_missing, options, register_setting_get, register_setting_set, register_setting_var, settings, settings_map
Class Method Details
.help(cmd) ⇒ Object
39
40
41
42
43
44
45
|
# File 'lib/ruby-debug/commands/stepping.rb', line 39
def help(cmd)
%{
n[ext][+-]?[ nnn]\tstep over once or nnn times,
\t\t'+' forces to move to another line.
\t\t'-' is the opposite of '+' and disables the force_stepping setting.
}
end
|
.help_command ⇒ Object
35
36
37
|
# File 'lib/ruby-debug/commands/stepping.rb', line 35
def help_command
'next'
end
|
Instance Method Details
#execute ⇒ Object
27
28
29
30
31
32
|
# File 'lib/ruby-debug/commands/stepping.rb', line 27
def execute
steps, force = parse_stepping_args("Next", @match)
return unless steps
@state.context.step_over steps, @state.frame_pos, force
@state.proceed
end
|
#regexp ⇒ Object
21
22
23
24
25
|
# File 'lib/ruby-debug/commands/stepping.rb', line 21
def regexp
/^\s* n(?:ext)?
([+-])?(?:\s+(\S+))?
\s*$/x
end
|