diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2013-04-08 18:41:23 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2013-04-08 18:41:23 +0000 |
commit | 4a16efa3e43e35f0cc9efe3a67f620f0017c3d36 (patch) | |
tree | 06099edc18d30894081a822b756f117cbe0b8207 /include/llvm/Support/FEnv.h | |
parent | 482e7bddf617ae804dc47133cb07eb4aa81e45de (diff) |
Diffstat (limited to 'include/llvm/Support/FEnv.h')
-rw-r--r-- | include/llvm/Support/FEnv.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/include/llvm/Support/FEnv.h b/include/llvm/Support/FEnv.h index f6f43337bd29e..8560ee0a8afec 100644 --- a/include/llvm/Support/FEnv.h +++ b/include/llvm/Support/FEnv.h @@ -12,8 +12,8 @@ // //===----------------------------------------------------------------------===// -#ifndef LLVM_SYSTEM_FENV_H -#define LLVM_SYSTEM_FENV_H +#ifndef LLVM_SUPPORT_FENV_H +#define LLVM_SUPPORT_FENV_H #include "llvm/Config/config.h" #include <cerrno> @@ -32,7 +32,7 @@ namespace sys { /// llvm_fenv_clearexcept - Clear the floating-point exception state. static inline void llvm_fenv_clearexcept() { -#ifdef HAVE_FENV_H +#if defined(HAVE_FENV_H) && HAVE_DECL_FE_ALL_EXCEPT feclearexcept(FE_ALL_EXCEPT); #endif errno = 0; @@ -43,7 +43,7 @@ static inline bool llvm_fenv_testexcept() { int errno_val = errno; if (errno_val == ERANGE || errno_val == EDOM) return true; -#ifdef HAVE_FENV_H +#if defined(HAVE_FENV_H) && HAVE_DECL_FE_ALL_EXCEPT && HAVE_DECL_FE_INEXACT if (fetestexcept(FE_ALL_EXCEPT & ~FE_INEXACT)) return true; #endif |