diff options
| author | shyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-05-22 12:36:57 +0000 |
|---|---|---|
| committer | shyouhei <shyouhei@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-05-22 12:36:57 +0000 |
| commit | 1735ddaad6a4a2f05a9f909e68e952554dbb3256 (patch) | |
| tree | f2c9f920feedf7a62b1b37623481737b884aa96e | |
| parent | 35eccd0d51ed8ef50e9f3d38d64c260000334ddb (diff) | |
| download | ruby-1735ddaad6a4a2f05a9f909e68e952554dbb3256.tar.gz ruby-1735ddaad6a4a2f05a9f909e68e952554dbb3256.tar.xz ruby-1735ddaad6a4a2f05a9f909e68e952554dbb3256.zip | |
merge -c 12116
git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8_6@12307 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
| -rw-r--r-- | ChangeLog | 5 | ||||
| -rw-r--r-- | bignum.c | 8 | ||||
| -rw-r--r-- | version.h | 2 |
3 files changed, 10 insertions, 5 deletions
@@ -1,3 +1,8 @@ +Tue May 22 21:29:08 2007 Nobuyoshi Nakada <nobu@ruby-lang.org> + + * bignum.c (rb_big2str0): round up for the most significant digit. + [ruby-core:10686] + Tue May 22 20:53:02 2007 Akinori MUSHA <knu@iDaemons.org> * ext/thread/thread.c (remove_one): Preserve List invariants; @@ -642,10 +642,10 @@ rb_big2str0(x, base, trim) j = j * 53L / 84 + 1; break; case 4: case 5: case 6: case 7: - j /= 2; + j = (j + 1) / 2; break; case 8: case 9: - j /= 3; + j = (j + 2) / 3; break; case 10: case 11: case 12: case 13: case 14: case 15: j = j * 28L / 93 + 1; @@ -653,10 +653,10 @@ rb_big2str0(x, base, trim) case 16: case 17: case 18: case 19: case 20: case 21: case 22: case 23: case 24: case 25: case 26: case 27: case 28: case 29: case 30: case 31: - j /= 4; + j = (j + 3) / 4; break; case 32: case 33: case 34: case 35: case 36: - j /= 5; + j = (j + 4) / 5; break; default: rb_raise(rb_eArgError, "illegal radix %d", base); @@ -2,7 +2,7 @@ #define RUBY_RELEASE_DATE "2007-05-22" #define RUBY_VERSION_CODE 186 #define RUBY_RELEASE_CODE 20070522 -#define RUBY_PATCHLEVEL 5 +#define RUBY_PATCHLEVEL 6 #define RUBY_VERSION_MAJOR 1 #define RUBY_VERSION_MINOR 8 |
