summaryrefslogtreecommitdiff
path: root/printf
diff options
context:
space:
mode:
authorKevin Ryde <user42@zip.com.au>2002-01-11 23:52:32 +0100
committerKevin Ryde <user42@zip.com.au>2002-01-11 23:52:32 +0100
commitb3ed09234503d5f218548506efb1d6517408671f (patch)
treec73799257a02eb180d4904be9162752aa445e1d3 /printf
parenta3d5e41f1d4b9ad0b7f979ec0ac2182f9d8aeb54 (diff)
downloadgmp-b3ed09234503d5f218548506efb1d6517408671f.tar.gz
* printf/repl-vsnprintf.c: Test HAVE_LONG_DOUBLE for long double.
Diffstat (limited to 'printf')
-rw-r--r--printf/repl-vsnprintf.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/printf/repl-vsnprintf.c b/printf/repl-vsnprintf.c
index fd5695bf6..bcf34b5f7 100644
--- a/printf/repl-vsnprintf.c
+++ b/printf/repl-vsnprintf.c
@@ -122,8 +122,10 @@ __gmp_replacement_vsnprintf (char *buf, size_t buf_size,
bit exponents, so the default is a maximum 4932 decimal digits. */
long_double_digits = 4932;
/* but if double == long double, then go with that size */
+#if HAVE_LONG_DOUBLE
if (sizeof (double) == sizeof (long double))
long_double_digits = double_digits;
+#endif
#ifdef LDBL_MAX_10_EXP
/* but in any case prefer a value the compiler says */
long_double_digits = LDBL_MAX_10_EXP;