summaryrefslogtreecommitdiff
path: root/uceil_exp2.c
diff options
context:
space:
mode:
authorpelissip <pelissip@280ebfd0-de03-0410-8827-d642c229c3f4>2004-01-28 14:22:05 +0000
committerpelissip <pelissip@280ebfd0-de03-0410-8827-d642c229c3f4>2004-01-28 14:22:05 +0000
commit0d0a6452168bfa99b9fef5808c81738245992bc0 (patch)
tree7adc2d00d0d52fd8c59f10349506fe5e1a3e727b /uceil_exp2.c
parent2f7d3ed598d3f6ec2925673ebc527d729a253576 (diff)
downloadmpfr-0d0a6452168bfa99b9fef5808c81738245992bc0.tar.gz
Better supports of non IEEE-754 floats (don't use anymore ieee_double_extract if _GMP_IEEE is not set).
git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@2650 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'uceil_exp2.c')
-rw-r--r--uceil_exp2.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/uceil_exp2.c b/uceil_exp2.c
index 16ad030d7..b6b010a21 100644
--- a/uceil_exp2.c
+++ b/uceil_exp2.c
@@ -19,9 +19,6 @@ along with the MPFR Library; see the file COPYING.LIB. If not, write to
the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
MA 02111-1307, USA. */
-#include "gmp.h"
-#include "gmp-impl.h"
-#include "mpfr.h"
#include "mpfr-impl.h"
/* returns y >= 2^d, assuming that d <= 1024 */
@@ -29,7 +26,11 @@ double
__gmpfr_ceil_exp2 (double d)
{
long exp;
+#if _GMP_IEEE_FLOATS
union ieee_double_extract x;
+#else
+ struct {double d;} x;
+#endif
MPFR_ASSERTN(d <= 1024.0);
exp = (long) d;