Skip to content
This repository was archived by the owner on Feb 2, 2024. It is now read-only.

Commit ec9e100

Browse files
Fixes compilation issue on linux (#912)
1 parent aff4c75 commit ec9e100

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

sdc/native/utils.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@
2929
#include "tbb/tbb.h"
3030
#include <memory>
3131
#include <iostream>
32+
#include <cmath>
3233

3334
#define HAS_TASK_SCHEDULER_INIT (TBB_INTERFACE_VERSION < 12002)
3435
#define HAS_TASK_SCHEDULER_HANDLE (TBB_INTERFACE_VERSION >= 12003)
@@ -159,13 +160,13 @@ void parallel_copy(void* src, void* dst, uint64_t len, uint64_t size)
159160
template<>
160161
bool nanless<float>(const float& left, const float& right)
161162
{
162-
return std::less<float>()(left, right) || (isnan(right) && !isnan(left));
163+
return std::less<float>()(left, right) || (std::isnan(right) && !std::isnan(left));
163164
}
164165

165166
template<>
166167
bool nanless<double>(const double& left, const double& right)
167168
{
168-
return std::less<double>()(left, right) || (isnan(right) && !isnan(left));
169+
return std::less<double>()(left, right) || (std::isnan(right) && !std::isnan(left));
169170
}
170171

171172
}

0 commit comments

Comments
 (0)