From: Duraid Madina Date: Mon, 16 May 2005 06:45:57 +0000 (+0000) Subject: HP-UX system headers make a mess of isinf(), so much so that gcc fixincludes X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=aaad8388e99c33eba31ea14ad619b6638e1b7bf0;p=oota-llvm.git HP-UX system headers make a mess of isinf(), so much so that gcc fixincludes can't patch it up for c++ (works in C though) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@22079 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Support/IsInf.cpp b/lib/Support/IsInf.cpp index 070ed4fcc1c..5160110bc2e 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 static int isinf(double x) { return !finite(x) && x==x; } +#elif defined(__hpux) +// HP-UX is "special" +#include +static int isinf(double x) { return ((x)==INFINITY)||((x)==-INFINITY); } #else # error "Don't know how to get isinf()" #endif