diff options
| author | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-09-02 00:51:39 +0000 |
|---|---|---|
| committer | nobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-09-02 00:51:39 +0000 |
| commit | 0c276c9e08cc2cbfd786a1be7977bbd44ec37184 (patch) | |
| tree | 9ccb2dc5d735cb90bb6b43bd2b7d14ba3134e589 | |
| parent | f85c05d8686c1e4390de0ead80514d7012988fad (diff) | |
| download | ruby-0c276c9e08cc2cbfd786a1be7977bbd44ec37184.tar.gz ruby-0c276c9e08cc2cbfd786a1be7977bbd44ec37184.tar.xz ruby-0c276c9e08cc2cbfd786a1be7977bbd44ec37184.zip | |
* eval.c (rb_eval): should not handle exceptions within rescue
argument. [ruby-talk:80804]
git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@4479 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
| -rw-r--r-- | ChangeLog | 5 | ||||
| -rw-r--r-- | eval.c | 6 |
2 files changed, 10 insertions, 1 deletions
@@ -1,3 +1,8 @@ +Tue Sep 2 09:51:36 2003 Nobuyoshi Nakada <nobu@ruby-lang.org> + + * eval.c (rb_eval): should not handle exceptions within rescue + argument. [ruby-talk:80804] + Tue Sep 2 00:44:37 2003 Nobuyoshi Nakada <nobu@ruby-lang.org> * re.c (rb_memsearch): fix overrun. [ruby-talk:80759] @@ -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)) { |
