From: Tadashi Saito Date: 2006-09-19T01:32:23+09:00 Subject: Re: [ ruby-Patches-5774 ] numeric.c fails to build on 64-bit platforms (Fedora Core 5 x86_64 gcc 4.1.1) Hi all, On Mon, 18 Sep 2006 12:03:15 +0900 Yukihiro Matsumoto wrote: > The patch has been merged. Thanks. Typo? Index: numeric.c =================================================================== RCS file: /src/ruby/numeric.c,v retrieving revision 1.146 diff -u -p -r1.146 numeric.c --- numeric.c 18 Sep 2006 03:17:06 -0000 1.146 +++ numeric.c 18 Sep 2006 16:31:44 -0000 @@ -1989,7 +1989,7 @@ fix_mul(VALUE x, VALUE y) if (FIXABLE(d)) return LONG2FIX(d); return rb_ll2inum(d); #else -# define SQRT_LONG_MAX ((SIZEOF_VALUE)1<<((SIZEOF_VALUE*CHAR_BIT-1)/2)) +# define SQRT_LONG_MAX ((SIGNED_VALUE)1<<((SIZEOF_VALUE*CHAR_BIT-1)/2)) /*tests if N*N would overflow*/ # define FIT_SQRT_LONG(n) (((n)=-SQRT_LONG_MAX)) if (FIT_SQRT_LONG(a) && FIT_SQRT_LONG(b)) -- Tadashi Saito