diff options
Diffstat (limited to 'MLKInteger.m')
-rw-r--r-- | MLKInteger.m | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/MLKInteger.m b/MLKInteger.m index 43af24d..b2ce0a8 100644 --- a/MLKInteger.m +++ b/MLKInteger.m @@ -165,12 +165,20 @@ DEFINE_MPZ_TWOARG_INTONLY_OPERATION (lcm:, mpz_lcm) -(BOOL) fitsIntoFixnum { +#ifdef NO_FIXNUMS + return NO; +#else return (mpz_sizeinbase (self->value, 2) <= (sizeof (id)) * 8 - 2); +#endif } -(id) fixnumValue { +#ifdef NO_FIXNUMS + return self; +#else return MLKFixnumWithInt ([self intValue]); +#endif } -(int) intValue |