Define SET_MANTISSA for long double type.
authordrepper <drepper>
Thu, 27 Mar 1997 01:48:50 +0000 (01:48 +0000)
committerdrepper <drepper>
Thu, 27 Mar 1997 01:48:50 +0000 (01:48 +0000)
stdlib/strtold.c
wcsmbs/wcstold.c

index 9d80543..1dc0ac3 100644 (file)
@@ -6,5 +6,12 @@
 #define        STRTOF          strtold
 #define        MPN2FLOAT       __mpn_construct_long_double
 #define        FLOAT_HUGE_VAL  HUGE_VALL
+#define SET_MANTISSA(flt, mant) \
+  do { union ieee854_long_double u;                                          \
+       u.d = (flt);                                                          \
+       u.ieee.mantissa0 = ((mant) >> 32) & 0x7fffffff;                       \
+       u.ieee.mantissa1 = (mant) & 0xffffffff;                               \
+       (flt) = u.d;                                                          \
+  } while (0)
 
 #include "strtod.c"
index 4cb68af..c94d47e 100644 (file)
 #define        MPN2FLOAT       __mpn_construct_long_double
 #define        FLOAT_HUGE_VAL  HUGE_VALL
 #define        USE_WIDE_CHAR   1
+#define SET_MANTISSA(flt, mant) \
+  do { union ieee854_long_double u;                                          \
+       u.d = (flt);                                                          \
+       u.ieee.mantissa0 = ((mant) >> 32) & 0x7fffffff;                       \
+       u.ieee.mantissa1 = (mant) & 0xffffffff;                               \
+       (flt) = u.d;                                                          \
+  } while (0)
 
 #include "../stdlib/strtod.c"