Merge pull request #20581 from ronchaine/nvmath-dont-use-obsolete-functions-on-linux

Do not use deprecated stuff that only glibc now implements
This commit is contained in:
Rémi Verschelde 2018-08-13 09:04:43 +02:00 committed by GitHub
commit fed34c3fef
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -181,10 +181,8 @@ namespace nv
{
#if NV_OS_WIN32 || NV_OS_XBOX || NV_OS_DURANGO
return _finite(f) != 0;
#elif NV_OS_DARWIN || NV_OS_FREEBSD || NV_OS_OPENBSD || NV_OS_ORBIS
#elif NV_OS_DARWIN || NV_OS_FREEBSD || NV_OS_OPENBSD || NV_OS_ORBIS || NV_OS_LINUX
return isfinite(f);
#elif NV_OS_LINUX
return finitef(f);
#else
# error "isFinite not supported"
#endif
@ -196,10 +194,8 @@ namespace nv
{
#if NV_OS_WIN32 || NV_OS_XBOX || NV_OS_DURANGO
return _isnan(f) != 0;
#elif NV_OS_DARWIN || NV_OS_FREEBSD || NV_OS_OPENBSD || NV_OS_ORBIS
#elif NV_OS_DARWIN || NV_OS_FREEBSD || NV_OS_OPENBSD || NV_OS_ORBIS || NV_OS_LINUX
return isnan(f);
#elif NV_OS_LINUX
return isnanf(f);
#else
# error "isNan not supported"
#endif