summaryrefslogtreecommitdiff
path: root/misc
diff options
context:
space:
mode:
authorRoland McGrath <roland@gnu.org>2004-12-29 09:19:59 +0000
committerRoland McGrath <roland@gnu.org>2004-12-29 09:19:59 +0000
commit525077e9f6a100e0d90af45f023dfb478a13ba8e (patch)
tree9309b31cfc81c1d691c2af5ff7648f4baa6842ff /misc
parent7d58530341304d403a6626d7f7a1913165fe2f32 (diff)
2004-12-19 Roland McGrath <roland@frob.com>
* gen-unicode-ctype.c (output_tables): Fix email address in output.
Diffstat (limited to 'misc')
-rw-r--r--misc/efgcvt_r.c25
-rw-r--r--misc/qefgcvt_r.c12
-rw-r--r--misc/tst-efgcvt.c7
3 files changed, 2 insertions, 42 deletions
diff --git a/misc/efgcvt_r.c b/misc/efgcvt_r.c
index 69cca9038f..ac2a5c45bf 100644
--- a/misc/efgcvt_r.c
+++ b/misc/efgcvt_r.c
@@ -1,5 +1,5 @@
/* Compatibility functions for floating point formatting, reentrant versions.
- Copyright (C) 1995,96,97,98,99,2000,01,02,04 Free Software Foundation, Inc.
+ Copyright (C) 1995,96,97,98,99,2000,01,02 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -31,7 +31,6 @@
# define FUNC_PREFIX
# define FLOAT_FMT_FLAG
# define FLOAT_NAME_EXT
-# define FLOAT_MIN_10_EXP DBL_MIN_10_EXP
# if DBL_MANT_DIG == 53
# define NDIGIT_MAX 17
# elif DBL_MANT_DIG == 24
@@ -44,17 +43,6 @@
# error "NDIGIT_MAX must be precomputed"
# define NDIGIT_MAX (lrint (ceil (M_LN2 / M_LN10 * DBL_MANT_DIG + 1.0)))
# endif
-# if DBL_MIN_10_EXP == -37
-# define FLOAT_MIN_10_NORM 1.0e-37
-# elif DBL_MIN_10_EXP == -307
-# define FLOAT_MIN_10_NORM 1.0e-307
-# elif DBL_MIN_10_EXP == -4931
-# define FLOAT_MIN_10_NORM 1.0e-4931
-# else
-/* libc can't depend on libm. */
-# error "FLOAT_MIN_10_NORM must be precomputed"
-# define FLOAT_MIN_10_NORM exp10 (DBL_MIN_10_EXP)
-# endif
#endif
#define APPEND(a, b) APPEND2 (a, b)
@@ -183,17 +171,6 @@ APPEND (FUNC_PREFIX, ecvt_r) (value, ndigit, decpt, sign, buf, len)
d = -value;
else
d = value;
- /* For denormalized numbers the d < 1.0 case below won't work,
- as f can overflow to +Inf. */
- if (d < FLOAT_MIN_10_NORM)
- {
- value /= FLOAT_MIN_10_NORM;
- if (value < 0.0)
- d = -value;
- else
- d = value;
- exponent += FLOAT_MIN_10_EXP;
- }
if (d < 1.0)
{
do
diff --git a/misc/qefgcvt_r.c b/misc/qefgcvt_r.c
index d5b2a799b3..66cc049ec8 100644
--- a/misc/qefgcvt_r.c
+++ b/misc/qefgcvt_r.c
@@ -24,7 +24,6 @@
#define FUNC_PREFIX q
#define FLOAT_FMT_FLAG "L"
#define FLOAT_NAME_EXT l
-#define FLOAT_MIN_10_EXP LDBL_MIN_10_EXP
#if LDBL_MANT_DIG == 64
# define NDIGIT_MAX 21
#elif LDBL_MANT_DIG == 53
@@ -41,16 +40,5 @@
# error "NDIGIT_MAX must be precomputed"
# define NDIGIT_MAX (lrint (ceil (M_LN2 / M_LN10 * LDBL_MANT_DIG + 1.0)))
#endif
-#if LDBL_MIN_10_EXP == -37
-# define FLOAT_MIN_10_NORM 1.0e-37L
-#elif LDBL_MIN_10_EXP == -307
-# define FLOAT_MIN_10_NORM 1.0e-307L
-#elif LDBL_MIN_10_EXP == -4931
-# define FLOAT_MIN_10_NORM 1.0e-4931L
-#else
-/* libc can't depend on libm. */
-# error "FLOAT_MIN_10_NORM must be precomputed"
-# define FLOAT_MIN_10_NORM exp10l (LDBL_MIN_10_EXP)
-#endif
#include "efgcvt_r.c"
diff --git a/misc/tst-efgcvt.c b/misc/tst-efgcvt.c
index 30ab0f17a0..91e5cf929e 100644
--- a/misc/tst-efgcvt.c
+++ b/misc/tst-efgcvt.c
@@ -1,4 +1,4 @@
-/* Copyright (C) 1998, 1999, 2000, 2004 Free Software Foundation, Inc.
+/* Copyright (C) 1998, 1999, 2000 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -20,7 +20,6 @@
# define _GNU_SOURCE 1
#endif
-#include <float.h>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
@@ -60,10 +59,6 @@ static testcase ecvt_tests[] =
{ 123.01, -4, 3, "" },
{ 126.71, -4, 3, "" },
{ 0.0, 4, 1, "0000" },
-#if DBL_MANT_DIG == 53
- { 0x1p-1074, 3, -323, "494" },
- { -0x1p-1074, 3, -323, "494" },
-#endif
/* -1.0 is end marker. */
{ -1.0, 0, 0, "" }
};