From: Chris Lattner Date: Mon, 25 Oct 2004 18:47:10 +0000 (+0000) Subject: Patch to support MSVC, contributed by Morten Ofstad X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=f0ae6c62e8cd53ef8c81f87e3a7abb0d15b6775b;p=oota-llvm.git Patch to support MSVC, contributed by Morten Ofstad git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17220 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Support/IsInf.cpp b/lib/Support/IsInf.cpp index c50eadff179..7087dd94c14 100644 --- a/lib/Support/IsInf.cpp +++ b/lib/Support/IsInf.cpp @@ -24,6 +24,9 @@ using std::isinf; // apparently this has been a problem with Solaris for years. # include static int isinf(double x) { return !finite(x) && x==x; } +#elif defined(_MSC_VER) +#include +#define isinf(X) (!_finite(X)) #else # error "Don't know how to get isinf()" #endif