diff options
author | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-09-01 12:02:36 +0000 |
---|---|---|
committer | akr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2007-09-01 12:02:36 +0000 |
commit | 2c8e7a50c1db8fea3fb012052828ad1eea51883f (patch) | |
tree | 9948c4ef01b8662c9d14a96cc228d7844af68b71 /compar.c | |
parent | 0c5e6ab2bb6726b0d70e99db25d5369e196d8ddc (diff) | |
download | ruby-2c8e7a50c1db8fea3fb012052828ad1eea51883f.tar.gz |
* include/ruby/ruby.h (struct RBignum): embed digits in RBignum for
small bignums.
* bignum.c: RBignum embeded digits implemented.
* include/ruby/intern.h: declare rb_big_resize.
* gc.c: don't free embedded digits.
* numeric.c: replace direct bignum field accessor by abstract field
accessor such as RBIGNUM(val)->sign to RBIGNUM_SIGN(val).
* sprintf.c: ditto.
* compar.c: ditto.
* marshal.c: ditto.
* random.c: ditto.
* .gdbinit: support embedded small bignums.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13330 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'compar.c')
-rw-r--r-- | compar.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -24,7 +24,7 @@ rb_cmpint(VALUE val, VALUE a, VALUE b) } if (FIXNUM_P(val)) return FIX2INT(val); if (TYPE(val) == T_BIGNUM) { - if (RBIGNUM(val)->sign) return 1; + if (RBIGNUM_SIGN(val)) return 1; return -1; } if (RTEST(rb_funcall(val, '>', 1, INT2FIX(0)))) return 1; |