summaryrefslogtreecommitdiff
path: root/perl.h
diff options
context:
space:
mode:
authorAndy Dougherty <doughera@lafayette.edu>2007-02-09 06:40:51 -0500
committerH.Merijn Brand <h.m.brand@xs4all.nl>2007-02-10 17:22:04 +0000
commited140128eb692ebeaa21f2775f8d3c34e9a94094 (patch)
tree1ed1e0da9af5eb071615d6d32c0bebd64980a3d3 /perl.h
parent75c442e4b9bb8eeee80e9ac09713243f25ff6ed6 (diff)
downloadperl-ed140128eb692ebeaa21f2775f8d3c34e9a94094.tar.gz
signbit detection (was [perl #39875] -0.0 loses signedness upon numeric comparison)
Message-ID: <Pine.LNX.4.62.0702091121400.10202@fractal.phys.lafayette.edu> p4raw-id: //depot/perl@30192
Diffstat (limited to 'perl.h')
-rw-r--r--perl.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/perl.h b/perl.h
index e2d4253f20..f1c88d4176 100644
--- a/perl.h
+++ b/perl.h
@@ -3409,6 +3409,10 @@ long vtohl(long n);
#define U_I(what) ((unsigned int)U_32(what))
#define U_L(what) U_32(what)
+#ifdef HAS_SIGNBIT
+# define Perl_signbit signbit
+#endif
+
/* These do not care about the fractional part, only about the range. */
#define NV_WITHIN_IV(nv) (I_V(nv) >= IV_MIN && I_V(nv) <= IV_MAX)
#define NV_WITHIN_UV(nv) ((nv)>=0.0 && U_V(nv) >= UV_MIN && U_V(nv) <= UV_MAX)