mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
7eaaee5405
Implements `catch`/`throw` non-local jump inherited from Lisp.
`catch([tag]) {|tag| block } -> obj`
Example:
```
catch(:foo) { 123 } # => 123
catch(:foo) { throw(:foo, 456) } # => 456
catch(:foo) { throw(:foo) } # => nil
```
6 lines
166 B
Ruby
6 lines
166 B
Ruby
MRuby::Gem::Specification.new('mruby-catch') do |spec|
|
|
spec.license = 'MIT'
|
|
spec.author = 'mruby developers'
|
|
spec.summary = 'Catch / Throw non-local Jump'
|
|
end
|