Skip to content

Commit

Permalink
fix comile error in melodic
Browse files Browse the repository at this point in the history
  • Loading branch information
lianghongzhuo committed May 6, 2020
1 parent 42f5666 commit 73eb461
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions map_creator/include/map_creator/mh5_ikfast.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -249,12 +249,12 @@ inline float IKatan2Simple(float fy, float fx)
}
inline float IKatan2(float fy, float fx)
{
if (isnan(fy))
if (std::isnan(fy))
{
IKFAST_ASSERT(!isnan(fx)); // if both are nan, probably wrong value will be returned
IKFAST_ASSERT(!std::isnan(fx)); // if both are nan, probably wrong value will be returned
return float(IKPI_2);
}
else if (isnan(fx))
else if (std::isnan(fx))
{
return 0;
}
Expand All @@ -266,12 +266,12 @@ inline double IKatan2Simple(double fy, double fx)
}
inline double IKatan2(double fy, double fx)
{
if (isnan(fy))
if (std::isnan(fy))
{
IKFAST_ASSERT(!isnan(fx)); // if both are nan, probably wrong value will be returned
IKFAST_ASSERT(!std::isnan(fx)); // if both are nan, probably wrong value will be returned
return IKPI_2;
}
else if (isnan(fx))
else if (std::isnan(fx))
{
return 0;
}
Expand All @@ -291,7 +291,7 @@ inline CheckValue< T > IKatan2WithCheck(T fy, T fx, T epsilon)
CheckValue< T > ret;
ret.valid = false;
ret.value = 0;
if (!isnan(fy) && !isnan(fx))
if (!std::isnan(fy) && !std::isnan(fx))
{
if (IKabs(fy) >= IKFAST_ATAN2_MAGTHRESH || IKabs(fx) > IKFAST_ATAN2_MAGTHRESH)
{
Expand Down Expand Up @@ -1151,7 +1151,7 @@ class IKSolver
j4array[1] = -j4array[0];
sj4array[1] = -sj4array[0];
}
else if (isnan(cj4array[0]))
else if (std::isnan(cj4array[0]))
{
// probably any value will work
j4valid[0] = true;
Expand Down

0 comments on commit 73eb461

Please sign in to comment.