mirror of
https://github.com/python/cpython.git
synced 2025-11-20 10:57:44 +00:00
Remove unused BCinfo fields and an unused macro.
This commit is contained in:
parent
9d87323445
commit
5a0b399aa9
1 changed files with 8 additions and 21 deletions
|
|
@ -200,12 +200,6 @@ typedef union { double d; ULong L[2]; } U;
|
||||||
#define STRTOD_DIGLIM 40
|
#define STRTOD_DIGLIM 40
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef DIGLIM_DEBUG
|
|
||||||
extern int strtod_diglim;
|
|
||||||
#else
|
|
||||||
#define strtod_diglim STRTOD_DIGLIM
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* The following definition of Storeinc is appropriate for MIPS processors.
|
/* The following definition of Storeinc is appropriate for MIPS processors.
|
||||||
* An alternative that might be better on some machines is
|
* An alternative that might be better on some machines is
|
||||||
* #define Storeinc(a,b,c) (*a++ = b << 16 | c & 0xffff)
|
* #define Storeinc(a,b,c) (*a++ = b << 16 | c & 0xffff)
|
||||||
|
|
@ -269,8 +263,7 @@ extern int strtod_diglim;
|
||||||
typedef struct BCinfo BCinfo;
|
typedef struct BCinfo BCinfo;
|
||||||
struct
|
struct
|
||||||
BCinfo {
|
BCinfo {
|
||||||
int dp0, dp1, dplen, dsign, e0, inexact;
|
int dp0, dp1, dplen, dsign, e0, nd, nd0, scale;
|
||||||
int nd, nd0, rounding, scale, uflchk;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#define FFFFFFFF 0xffffffffUL
|
#define FFFFFFFF 0xffffffffUL
|
||||||
|
|
@ -1318,7 +1311,7 @@ _Py_dg_strtod(const char *s00, char **se)
|
||||||
BCinfo bc;
|
BCinfo bc;
|
||||||
Bigint *bb, *bb1, *bd, *bd0, *bs, *delta;
|
Bigint *bb, *bb1, *bd, *bd0, *bs, *delta;
|
||||||
|
|
||||||
sign = nz0 = nz = bc.dplen = bc.uflchk = 0;
|
sign = nz0 = nz = bc.dplen = 0;
|
||||||
dval(&rv) = 0.;
|
dval(&rv) = 0.;
|
||||||
for(s = s00;;s++) switch(*s) {
|
for(s = s00;;s++) switch(*s) {
|
||||||
case '-':
|
case '-':
|
||||||
|
|
@ -1555,11 +1548,11 @@ _Py_dg_strtod(const char *s00, char **se)
|
||||||
/* Put digits into bd: true value = bd * 10^e */
|
/* Put digits into bd: true value = bd * 10^e */
|
||||||
|
|
||||||
bc.nd = nd;
|
bc.nd = nd;
|
||||||
bc.nd0 = nd0; /* Only needed if nd > strtod_diglim, but done here */
|
bc.nd0 = nd0; /* Only needed if nd > STRTOD_DIGLIM, but done here */
|
||||||
/* to silence an erroneous warning about bc.nd0 */
|
/* to silence an erroneous warning about bc.nd0 */
|
||||||
/* possibly not being initialized. */
|
/* possibly not being initialized. */
|
||||||
if (nd > strtod_diglim) {
|
if (nd > STRTOD_DIGLIM) {
|
||||||
/* ASSERT(strtod_diglim >= 18); 18 == one more than the */
|
/* ASSERT(STRTOD_DIGLIM >= 18); 18 == one more than the */
|
||||||
/* minimum number of decimal digits to distinguish double values */
|
/* minimum number of decimal digits to distinguish double values */
|
||||||
/* in IEEE arithmetic. */
|
/* in IEEE arithmetic. */
|
||||||
i = j = 18;
|
i = j = 18;
|
||||||
|
|
@ -1767,10 +1760,8 @@ _Py_dg_strtod(const char *s00, char **se)
|
||||||
/* accept rv */
|
/* accept rv */
|
||||||
break;
|
break;
|
||||||
/* rv = smallest denormal */
|
/* rv = smallest denormal */
|
||||||
if (bc.nd >nd) {
|
if (bc.nd >nd)
|
||||||
bc.uflchk = 1;
|
|
||||||
break;
|
break;
|
||||||
}
|
|
||||||
goto undfl;
|
goto undfl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -1786,10 +1777,8 @@ _Py_dg_strtod(const char *s00, char **se)
|
||||||
else {
|
else {
|
||||||
dval(&rv) -= ulp(&rv);
|
dval(&rv) -= ulp(&rv);
|
||||||
if (!dval(&rv)) {
|
if (!dval(&rv)) {
|
||||||
if (bc.nd >nd) {
|
if (bc.nd >nd)
|
||||||
bc.uflchk = 1;
|
|
||||||
break;
|
break;
|
||||||
}
|
|
||||||
goto undfl;
|
goto undfl;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -1801,10 +1790,8 @@ _Py_dg_strtod(const char *s00, char **se)
|
||||||
aadj = aadj1 = 1.;
|
aadj = aadj1 = 1.;
|
||||||
else if (word1(&rv) || word0(&rv) & Bndry_mask) {
|
else if (word1(&rv) || word0(&rv) & Bndry_mask) {
|
||||||
if (word1(&rv) == Tiny1 && !word0(&rv)) {
|
if (word1(&rv) == Tiny1 && !word0(&rv)) {
|
||||||
if (bc.nd >nd) {
|
if (bc.nd >nd)
|
||||||
bc.uflchk = 1;
|
|
||||||
break;
|
break;
|
||||||
}
|
|
||||||
goto undfl;
|
goto undfl;
|
||||||
}
|
}
|
||||||
aadj = 1.;
|
aadj = 1.;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue