diff --git a/ChangeLog b/ChangeLog index 2617c0326b..27e902b479 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Sat Mar 12 09:50:27 2016 Nobuyoshi Nakada + + * vm_eval.c (rb_f_catch): [DOC] fix malformed RDoc syntax, "+...+" + cannot enclose non-identifier characters. + a patch by Sebastian S in [ruby-core:74278]. [Bug#12170] + Sat Mar 12 02:44:48 2016 Tanaka Akira * test/lib/test/unit.rb: describe !/REGEXP/ in the help message. diff --git a/vm_eval.c b/vm_eval.c index c2fca2c844..686b7e030c 100644 --- a/vm_eval.c +++ b/vm_eval.c @@ -1938,10 +1938,10 @@ catch_i(VALUE tag, VALUE data) * * catch(1) { 123 } # => 123 * - * If +throw(tag2, val)+ is called, Ruby searches up its stack for a +catch+ - * block whose +tag+ has the same +object_id+ as _tag2_. When found, the block - * stops executing and returns _val_ (or +nil+ if no second argument was given - * to +throw+). + * If throw(tag2, val) is called, Ruby searches up its stack for + * a +catch+ block whose +tag+ has the same +object_id+ as _tag2_. When found, + * the block stops executing and returns _val_ (or +nil+ if no second argument + * was given to +throw+). * * catch(1) { throw(1, 456) } # => 456 * catch(1) { throw(1) } # => nil