projects
/
gnulib.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
warnings: Support non-literal arguments, and let the user choose the variable
[gnulib.git]
/
tests
/
test-vasnprintf-posix.c
diff --git
a/tests/test-vasnprintf-posix.c
b/tests/test-vasnprintf-posix.c
index
aa537fb
..
bf12548
100644
(file)
--- a/
tests/test-vasnprintf-posix.c
+++ b/
tests/test-vasnprintf-posix.c
@@
-57,8
+57,14
@@
have_minus_zero ()
double zerod = 0.0;
/* On HP-UX 10.20, negating 0.0L does not yield -0.0L.
double zerod = 0.0;
/* On HP-UX 10.20, negating 0.0L does not yield -0.0L.
- So we use minus_zerol instead. */
+ So we use minus_zerol instead.
+ Note that the expression -LDBL_MIN * LDBL_MIN does not work on other
+ platforms, such as when cross-compiling to PowerPC on MacOS X 10.5. */
+#if defined __hpux || defined __sgi
long double minus_zerol = -LDBL_MIN * LDBL_MIN;
long double minus_zerol = -LDBL_MIN * LDBL_MIN;
+#else
+long double minus_zerol = -0.0L;
+#endif
/* Representation of an 80-bit 'long double' as an initializer for a sequence
of 'unsigned int' words. */
/* Representation of an 80-bit 'long double' as an initializer for a sequence
of 'unsigned int' words. */