Class: Cond::CondPrivate::RestartableSection
- Inherits:
-
CodeSection
- Object
- CodeSection
- Cond::CondPrivate::RestartableSection
- Defined in:
- lib/cond.rb
Overview
:nodoc:
Instance Method Summary collapse
-
#initialize(&block) ⇒ RestartableSection
constructor
A new instance of RestartableSection.
- #restart(sym, message, &block) ⇒ Object
Methods inherited from CodeSection
Methods included from SymbolGenerator
Constructor Details
#initialize(&block) ⇒ RestartableSection
303 304 305 |
# File 'lib/cond.rb', line 303 def initialize(&block) super(:with_restarts, &block) end |
Instance Method Details
#restart(sym, message, &block) ⇒ Object
307 308 309 |
# File 'lib/cond.rb', line 307 def restart(sym, , &block) Cond.restarts_stack.last[sym] = Restart.new(, &block) end |