ruby-changes:38482
From: nagachika <ko1@a...>
Date: Thu, 21 May 2015 01:21:46 +0900 (JST)
Subject: [ruby-changes:38482] nagachika:r50563 (ruby_2_2): merge revision(s) 49390: [Backport #10775]
nagachika 2015-05-21 01:21:30 +0900 (Thu, 21 May 2015) New Revision: 50563 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=50563 Log: merge revision(s) 49390: [Backport #10775] * vm_insnhelper.c (vm_throw_start): search the target to break from a block with nested rescue, from the nested blocks. [ruby-core:67765] [Bug #10775] [Fix GH-820] Modified directories: branches/ruby_2_2/ Modified files: branches/ruby_2_2/ChangeLog branches/ruby_2_2/bootstraptest/test_block.rb branches/ruby_2_2/version.h branches/ruby_2_2/vm_insnhelper.c Index: ruby_2_2/ChangeLog =================================================================== --- ruby_2_2/ChangeLog (revision 50562) +++ ruby_2_2/ChangeLog (revision 50563) @@ -1,3 +1,9 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_2/ChangeLog#L1 +Thu May 21 01:07:41 2015 Misumi Rize <r@a...> + + * vm_insnhelper.c (vm_throw_start): search the target to break + from a block with nested rescue, from the nested blocks. + [ruby-core:67765] [Bug #10775] [Fix GH-820] + Thu May 21 00:55:45 2015 Koichi Sasada <ko1@a...> * vm_args.c: protect value stack from calling other methods Index: ruby_2_2/bootstraptest/test_block.rb =================================================================== --- ruby_2_2/bootstraptest/test_block.rb (revision 50562) +++ ruby_2_2/bootstraptest/test_block.rb (revision 50563) @@ -597,3 +597,17 @@ assert_equal 'true', %q{ https://github.com/ruby/ruby/blob/trunk/ruby_2_2/bootstraptest/test_block.rb#L597 C1.new.foo{} } +assert_equal 'ok', %q{ + 1.times do + begin + raise + rescue + begin + raise + rescue + break + end + end + end + 'ok' +} Index: ruby_2_2/version.h =================================================================== --- ruby_2_2/version.h (revision 50562) +++ ruby_2_2/version.h (revision 50563) @@ -1,6 +1,6 @@ https://github.com/ruby/ruby/blob/trunk/ruby_2_2/version.h#L1 #define RUBY_VERSION "2.2.3" #define RUBY_RELEASE_DATE "2015-05-21" -#define RUBY_PATCHLEVEL 112 +#define RUBY_PATCHLEVEL 113 #define RUBY_RELEASE_YEAR 2015 #define RUBY_RELEASE_MONTH 5 Index: ruby_2_2/vm_insnhelper.c =================================================================== --- ruby_2_2/vm_insnhelper.c (revision 50562) +++ ruby_2_2/vm_insnhelper.c (revision 50563) @@ -630,13 +630,11 @@ vm_throw_start(rb_thread_t * const th, r https://github.com/ruby/ruby/blob/trunk/ruby_2_2/vm_insnhelper.c#L630 rb_iseq_t *base_iseq = GET_ISEQ(); escape_cfp = reg_cfp; - search_parent: - if (base_iseq->type != ISEQ_TYPE_BLOCK) { + while (base_iseq->type != ISEQ_TYPE_BLOCK) { if (escape_cfp->iseq->type == ISEQ_TYPE_CLASS) { escape_cfp = RUBY_VM_PREVIOUS_CONTROL_FRAME(escape_cfp); ep = escape_cfp->ep; base_iseq = escape_cfp->iseq; - goto search_parent; } else { ep = VM_EP_PREV_EP(ep); Property changes on: ruby_2_2 ___________________________________________________________________ Modified: svn:mergeinfo Merged /trunk:r49390 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/