summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2003-11-16 09:11:01 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2003-11-16 09:11:01 +0000
commit4e2fd6be8d1d731eb83de0de3f21382296e674c9 (patch)
tree9996edd0073c606ae91921bed841b70a61e883cf
parent1fc7d20da2b39f926c16c1d65ac90fcf37eb3466 (diff)
* eval.c (rb_eval): iterator should return value from next inside
begin/rescue/end. (ruby-bugs:PR#1218) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4969 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog11
-rw-r--r--eval.c9
2 files changed, 16 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index 0648bd18a8..5a547d7942 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Sun Nov 16 18:10:57 2003 Nobuyoshi Nakada <nobu@ruby-lang.org>
+
+ * eval.c (rb_eval): iterator should return value from next inside
+ begin/rescue/end. (ruby-bugs:PR#1218)
+
Sun Nov 16 13:26:07 2003 Yukihiro Matsumoto <matz@ruby-lang.org>
* eval.c (eval): prepend error position in evaluating string to
@@ -35,7 +40,7 @@ Sat Nov 15 22:16:42 2003 GOTOU Yuuzou <gotoyuzo@notwork.org>
Sat Nov 15 10:05:40 2003 Tanaka Akira <akr@m17n.org>
- * lib/open-uri.rb (OpenURI.open_loop, OpenURI::HTTP#proxy_open):
+ * lib/open-uri.rb (OpenURI.open_loop, OpenURI::HTTP#proxy_open):
refactored to support options.
(Buffer): maintain size by this class.
@@ -47,7 +52,7 @@ Fri Nov 14 13:21:30 2003 Hidetoshi NAGAI <nagai@ai.kyutech.ac.jp>
* ext/tcltklib/tcltklib.c: fix (en-bugged at 2003/11/07)
- * ext/tk/lib/tkdialog.rb: TkDialog.new accepts a parent widget
+ * ext/tk/lib/tkdialog.rb: TkDialog.new accepts a parent widget
argument [ruby-talk:85066]
Thu Nov 13 20:53:35 2003 Tanaka Akira <akr@m17n.org>
@@ -57,7 +62,7 @@ Thu Nov 13 20:53:35 2003 Tanaka Akira <akr@m17n.org>
Thu Nov 13 19:17:00 2003 Hidetoshi NAGAI <nagai@ai.kyutech.ac.jp>
- * lib/test/unit/ui/tk/testrunner.rb: use grid and panedwindow
+ * lib/test/unit/ui/tk/testrunner.rb: use grid and panedwindow
(if available)
Thu Nov 13 17:56:41 2003 Tanaka Akira <akr@m17n.org>
diff --git a/eval.c b/eval.c
index 4a582ded66..31c1033e7e 100644
--- a/eval.c
+++ b/eval.c
@@ -2862,6 +2862,7 @@ rb_eval(self, n)
}
else if (state != TAG_RAISE) {
ruby_errinfo = e_info;
+ result = prot_tag->retval;
}
}
else if (state == TAG_RAISE) {
@@ -2880,8 +2881,14 @@ rb_eval(self, n)
resq = resq->nd_head; /* next rescue */
}
}
+ else {
+ result = prot_tag->retval;
+ }
POP_TAG();
- if (state) JUMP_TAG(state);
+ if (state) {
+ if (state == TAG_NEXT) prot_tag->retval = result;
+ JUMP_TAG(state);
+ }
/* no exception raised */
if (!rescuing && (node = node->nd_else)) { /* else clause given */
goto again;