なかだです。
test/ruby/test_iterator.rb:test_ljumpのエラーにもならずに終了し
てしまう件ですが、どうもブロックの生成されたスコープを通り越し
てbreakしてしまってるような雰囲気です。
# ljump_test(false, get_block{break}) # !! This line terminates testrunner... please sombody fix it.
Index: eval.c
===================================================================
RCS file: /cvs/ruby/src/ruby/eval.c,v
retrieving revision 1.530
diff -u -2 -p -r1.530 eval.c
--- eval.c 2 Sep 2003 00:51:39 -0000 1.530
+++ eval.c 4 Sep 2003 16:46:25 -0000
@@ -1521,4 +1521,5 @@ localjump_reason(exc)
}
+NORETURN(static void jump_tag_but_local_jump _((int)));
static void
jump_tag_but_local_jump(state)
@@ -4024,6 +4025,7 @@ localjump_destination(state, scope, retv
tt->dst = (VALUE)scope;
tt->retval = retval;
- break;
+ JUMP_TAG(state);
}
+ if (tt->tag == PROT_FUNC && tt->scope == scope) break;
if (tt->tag == PROT_THREAD) {
rb_raise(rb_eThreadError, "%s jump can't across threads",
@@ -4032,8 +4034,5 @@ localjump_destination(state, scope, retv
tt = tt->prev;
}
- if (!tt) {
- jump_tag_but_local_jump(state);
- }
- JUMP_TAG(state);
+ jump_tag_but_local_jump(state);
}
--
--- 僕の前にBugはない。
--- 僕の後ろにBugはできる。
中田 伸悦