diff options
author | marcandre <marcandre@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-05-08 04:50:09 +0000 |
---|---|---|
committer | marcandre <marcandre@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2010-05-08 04:50:09 +0000 |
commit | 1dee5e34a3d397eb96db0b6bcc8e9cb9858975d0 (patch) | |
tree | 5822fdfead1635f2f78cfd0ee69bd61c217ad07f /proc.c | |
parent | b140b77926a6e62228f1152157d0348ff5724f89 (diff) | |
download | ruby-1dee5e34a3d397eb96db0b6bcc8e9cb9858975d0.tar.gz |
* error.c: RDoc for subclasses of Exception. [ruby-core:28394]
* cont.c: ditto
* enumerator.c: ditto
* io.c: ditto
* math.c: ditto
* numeric.c: ditto
* proc.c: ditto
* re.c: ditto
* thread.c: ditto
* transcode.c: ditto. Thanks to Run Paint for some of the documentation.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@27671 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'proc.c')
-rw-r--r-- | proc.c | 43 |
1 files changed, 43 insertions, 0 deletions
@@ -2007,6 +2007,49 @@ proc_curry(int argc, VALUE *argv, VALUE self) } /* + * Document-class: LocalJumpError + * + * Raised when Ruby can't yield as requested. + * + * A typical scenario is attempting to yield when no block is given: + * + * def call_block + * yield 42 + * end + * call_block + * + * <em>raises the exception:</em> + * + * LocalJumpError: no block given (yield) + * + * A more subtle example: + * + * def get_me_a_return + * Proc.new { return 42 } + * end + * get_me_a_return.call + * + * <em>raises the exception:</em> + * + * LocalJumpError: unexpected return + */ + +/* + * Document-class: SystemStackError + * + * Raised in case of a stack overflow. + * + * def me_myself_and_i + * me_myself_and_i + * end + * me_myself_and_i + * + * <em>raises the exception:</em> + * + * SystemStackError: stack level too deep + */ + +/* * <code>Proc</code> objects are blocks of code that have been bound to * a set of local variables. Once bound, the code may be called in * different contexts and still access those variables. |