Project

General

Profile

Bug #5160 ยป infinity-nan-bigendian.patch

ngoto (Naohisa Goto), 08/05/2011 08:33 PM

View differences:

numeric.c (working copy)
#endif
#ifdef HAVE_INFINITY
#elif BYTE_ORDER == LITTLE_ENDIAN
#elif !defined(WORDS_BIGENDIAN) /* BYTE_ORDER == LITTLE_ENDIAN */
const unsigned char rb_infinity[] = "\x00\x00\x80\x7f";
#else
const unsigned char rb_infinity[] = "\x7f\x80\x00\x00";
#endif
#ifdef HAVE_NAN
#elif BYTE_ORDER == LITTLE_ENDIAN
#elif !defined(WORDS_BIGENDIAN) /* BYTE_ORDER == LITTLE_ENDIAN */
const unsigned char rb_nan[] = "\x00\x00\xc0\x7f";
#else
const unsigned char rb_nan[] = "\x7f\xc0\x00\x00";
    (1-1/1)