diff --git a/ChangeLog b/ChangeLog index 1d950551df..a29f931c38 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Tue Sep 2 09:51:36 2003 Nobuyoshi Nakada + + * eval.c (rb_eval): should not handle exceptions within rescue + argument. [ruby-talk:80804] + Tue Sep 2 00:44:37 2003 Nobuyoshi Nakada * re.c (rb_memsearch): fix overrun. [ruby-talk:80759] diff --git a/eval.c b/eval.c index c66f4415a7..c65c31419e 100644 --- a/eval.c +++ b/eval.c @@ -2782,7 +2782,10 @@ rb_eval(self, n) result = rb_eval(self, node->nd_head); } else if (rescuing) { - if (state == TAG_RETRY) { + if (rescuing < 0) { + /* in rescue argument, just reraise */ + } + else if (state == TAG_RETRY) { rescuing = state = 0; e_info = ruby_errinfo = Qnil; result = rb_eval(self, node->nd_head); @@ -2794,6 +2797,7 @@ rb_eval(self, n) else if (state == TAG_RAISE) { NODE *resq = node->nd_resq; + rescuing = -1; while (resq) { ruby_current_node = resq; if (handle_rescue(self, resq)) {