summaryrefslogtreecommitdiff
path: root/missing/isinf.c
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-11-13 16:54:27 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2007-11-13 16:54:27 +0000
commit093fe3b839b9d3c5890e0d31faaefcce5d8acf7c (patch)
tree1d4886012d5de5851aa97f47dd8e9bb5161e1128 /missing/isinf.c
parentfd3ef45a423675e71b22952b59963058039063a6 (diff)
* missing/isinf.c (isinf): don't define is the macro is defined.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13915 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'missing/isinf.c')
-rw-r--r--missing/isinf.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/missing/isinf.c b/missing/isinf.c
index eecb3eb..4aef51b 100644
--- a/missing/isinf.c
+++ b/missing/isinf.c
@@ -27,11 +27,18 @@ isinf(double n)
#include <ieeefp.h>
#endif
+/*
+ * isinf may be provided only as a macro.
+ * ex. HP-UX, Solaris 10
+ * http://www.gnu.org/software/automake/manual/autoconf/Function-Portability.html
+ */
+#ifndef isinf
int
isinf(double n)
{
return (!finite(n) && !isnan(n));
}
+#endif
#else