diff options
author | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2001-03-14 04:45:46 +0000 |
---|---|---|
committer | matz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2001-03-14 04:45:46 +0000 |
commit | 53ff8df72f5e2fc6318a25474bd8c3950a2c7c29 (patch) | |
tree | 7dc5a4dbee4d7fb9df19bd0c5b856e3ea0bc2f85 /bignum.c | |
parent | a22cbaa697e28789acfba1204f502d62e4db8fab (diff) | |
download | ruby-53ff8df72f5e2fc6318a25474bd8c3950a2c7c29.tar.gz |
* eval.c (rb_yield_0): 0 (= Qfalse) is a valid value, so that
default self should be checked by klass == 0.
* bignum.c (rb_cstr2inum): should disallow '++1', '+-1', etc.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1251 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'bignum.c')
-rw-r--r-- | bignum.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -209,6 +209,10 @@ rb_cstr2inum(str, base) str++; sign = 0; } + if (str[0] == '+' || str[0] == '-') { + if (badcheck) goto bad; + return INT2FIX(0); + } if (base == 0) { if (str[0] == '0') { if (str[1] == 'x' || str[1] == 'X') { |