Class: Break::NextCommand
- Inherits:
-
TracePointCommand
- Object
- Command
- TracePointCommand
- Break::NextCommand
- Defined in:
- lib/break/commands/next_command.rb
Instance Method Summary collapse
Methods inherited from TracePointCommand
Methods inherited from Command
Constructor Details
This class inherits a constructor from Break::TracePointCommand
Instance Method Details
#execute_trace(trace) ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 |
# File 'lib/break/commands/next_command.rb', line 7 def execute_trace(trace, *) case trace.event when :call, :class, :b_call context.bindings << trace.binding context.depth += 1 when :return, :end, :b_return context.bindings.pop context.depth -= 1 when :line return if context.depth.positive? trace.disable context!(*context.bindings[0...-1], trace.binding) end end |