summaryrefslogtreecommitdiff
path: root/Objects/stringobject.c
diff options
context:
space:
mode:
authorMark Dickinson <dickinsm@gmail.com>2009-03-29 14:37:51 +0000
committerMark Dickinson <dickinsm@gmail.com>2009-03-29 14:37:51 +0000
commit2e648ecc7d7339b0a932a64c521cae8da791bfcd (patch)
treee3fe18c1e8b6f0e1ce332502a343af8b79706568 /Objects/stringobject.c
parent310916212e3320b3b100ff57bbc4ce5331ca1cfe (diff)
downloadcpython-git-2e648ecc7d7339b0a932a64c521cae8da791bfcd.tar.gz
Issue #532631: Replace confusing fabs(x)/1e25 >= 1e25 test
with fabs(x) >= 1e50, and fix documentation.
Diffstat (limited to 'Objects/stringobject.c')
-rw-r--r--Objects/stringobject.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/stringobject.c b/Objects/stringobject.c
index 8f82f4f48e..3b5d331bed 100644
--- a/Objects/stringobject.c
+++ b/Objects/stringobject.c
@@ -4344,7 +4344,7 @@ formatfloat(char *buf, size_t buflen, int flags,
}
if (prec < 0)
prec = 6;
- if (type == 'f' && fabs(x)/1e25 >= 1e25)
+ if (type == 'f' && fabs(x) >= 1e50)
type = 'g';
/* Worst case length calc to ensure no buffer overrun: