diff options
Diffstat (limited to 'libmath/dtoa.c')
| -rw-r--r-- | libmath/dtoa.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/libmath/dtoa.c b/libmath/dtoa.c index 0a73ef5a..95cf2738 100644 --- a/libmath/dtoa.c +++ b/libmath/dtoa.c @@ -26,13 +26,18 @@ #define Sign_Extend(a,b) if (b < 0) a |= 0xffff0000; +#ifdef USE_FPdbleword +#define word0(x) ((unsigned long *)&x)->hi +#define word1(x) ((unsigned long *)&x)->lo +#else #ifdef __LITTLE_ENDIAN -#define word0(x) ((unsigned long *)&x)[1] -#define word1(x) ((unsigned long *)&x)[0] +#define word0(x) ((FPdbleword*)&x)[1] +#define word1(x) ((FPdbleword*)&x)[0] #else #define word0(x) ((unsigned long *)&x)[0] #define word1(x) ((unsigned long *)&x)[1] #endif +#endif /* #define P DBL_MANT_DIG */ /* Ten_pmax = floor(P*log(2)/log(5)) */ |
