diff options
Diffstat (limited to 'bignum.c')
-rw-r--r-- | bignum.c | 12 |
1 files changed, 12 insertions, 0 deletions
@@ -53,6 +53,12 @@ bigzero_p(VALUE x) } int +rb_bigzero_p(VALUE x) +{ + return BIGZEROP(x); +} + +int rb_cmpint(VALUE val, VALUE a, VALUE b) { if (NIL_P(val)) { @@ -143,6 +149,12 @@ bignew_1(VALUE klass, long len, int sign) #define bignew(len,sign) bignew_1(rb_cBignum,len,sign) VALUE +rb_big_new(long len, int sign) +{ + return bignew(len, sign != 0); +} + +VALUE rb_big_clone(VALUE x) { VALUE z = bignew_1(CLASS_OF(x), RBIGNUM_LEN(x), RBIGNUM_SIGN(x)); |