aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Support/IsInf.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Support/IsInf.cpp')
-rw-r--r--lib/Support/IsInf.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/Support/IsInf.cpp b/lib/Support/IsInf.cpp
index 070ed4f..5160110 100644
--- a/lib/Support/IsInf.cpp
+++ b/lib/Support/IsInf.cpp
@@ -29,6 +29,10 @@ static int isinf(double x) { return !finite(x) && x==x; }
// system header /usr/include/math.h
# include <math.h>
static int isinf(double x) { return !finite(x) && x==x; }
+#elif defined(__hpux)
+// HP-UX is "special"
+#include <math.h>
+static int isinf(double x) { return ((x)==INFINITY)||((x)==-INFINITY); }
#else
# error "Don't know how to get isinf()"
#endif