diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-08-01 20:19:40 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2003-08-01 20:19:40 +0000 |
commit | 2e9ba7e77ba49410e62c8e93ef3eafdc1cdb795b (patch) | |
tree | 310acbe967be75d9ab9db888256428c694b7de21 | |
parent | cdacb127fc82920afed967222716d6775273432a (diff) | |
download | ruby-2e9ba7e77ba49410e62c8e93ef3eafdc1cdb795b.tar.gz |
* eval.c (rb_yield_0): code clean up according to Nobu's patch.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@4278 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r-- | eval.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -4100,8 +4100,7 @@ rb_yield_0(val, self, klass, flags, avalue) if (avalue) { len = RARRAY(val)->len; if (len == 0) { - val = Qnil; - goto multi_values; + goto zero_arg; } if (len == 1) { val = RARRAY(val)->ptr[0]; @@ -4111,6 +4110,7 @@ rb_yield_0(val, self, klass, flags, avalue) } } else if (val == Qundef) { + zero_arg: val = Qnil; multi_values: { |