summaryrefslogtreecommitdiffstats
path: root/eval.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2005-07-29 00:58:14 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2005-07-29 00:58:14 +0000
commit77138cc235e5e8ba49982996e33eedb4e200c548 (patch)
tree52f6c16de4730aa5676c030fa3e822ca95e27f76 /eval.c
parentf602da0c0dbc97b498849435163a189c0f426607 (diff)
downloadruby-77138cc235e5e8ba49982996e33eedb4e200c548.tar.gz
ruby-77138cc235e5e8ba49982996e33eedb4e200c548.tar.xz
ruby-77138cc235e5e8ba49982996e33eedb4e200c548.zip
* eval.c (rb_call0): fix calling zsuper from a method with anonymous
rest argument. [ruby-dev:26639] git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@8863 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'eval.c')
-rw-r--r--eval.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/eval.c b/eval.c
index fc4e3afce..ab6e462dc 100644
--- a/eval.c
+++ b/eval.c
@@ -5771,7 +5771,7 @@ formal_assign(recv, node, argc, argv, local_vars)
rb_eval(recv, opt);
}
}
- if (node->nd_rest && !NIL_P(node->nd_rest)) {
+ if (RTEST(node->nd_rest)) {
VALUE v;
if (argc > 0)
@@ -5923,7 +5923,7 @@ rb_call0(klass, recv, id, oid, argc, argv, body, nosuper)
}
if (node) {
formal_assign(recv, node, argc, argv, local_vars);
- if (node->nd_rest) {
+ if (RTEST(node->nd_rest)) {
ruby_frame->argc = -(ruby_frame->argc - argc)-1;
}
}