Class: Symbol
Instance Method Summary collapse
-
#thrown?(*args) ⇒ Boolean
Does the block throw this symbol? Throwing another symbol counts as no; any error is raised as usual.
Instance Method Details
#thrown?(*args) ⇒ Boolean
Does the block throw this symbol? Throwing another symbol counts as no; any error is raised as usual.
116 117 118 119 120 121 122 123 124 125 |
# File 'lib/assay/ae/core_ext.rb', line 116 def thrown?(*args) catch(self) do begin yield(*args) rescue UncaughtThrowError end return false end return true end |