The project fails to compile on Macos, in the devel branch, with the error:
rc/positionControl-accuracy/PositionControlAccuracy.cpp -o /Users/nunoguedelha/dev/robotology-superbuild/build/robotology/icub-tests/src/positionControl-accuracy/iCub-Tests.build/Release/PositionControlAccuracy.build/Objects-normal/x86_64/PositionControlAccuracy.o
/Users/nunoguedelha/dev/robotology-superbuild/robotology/icub-tests/src/positionControl-accuracy/PositionControlAccuracy.cpp:108:17: error: no member named 'nanf' in namespace 'std'; did you mean simply 'nanf'?
double p_Kp=std::nanf("");
^~~~~~~~~
nanf
isnan(), nanf(), etc.., are defined in the namespacestd in the header <cmath.h> (*) but not in the header <math> (**) which is the one included in the PositionControlAccuracy.cpp file.
The project fails to compile on Macos, in the
devel
branch, with the error:isnan()
,nanf()
, etc.., are defined in the namespacestd
in the header<cmath.h>
(*) but not in the header<math>
(**) which is the one included in thePositionControlAccuracy.cpp
file.(*) C++ standard: https://en.cppreference.com/w/cpp/numeric/math/nan () C** stancdard: https://en.cppreference.com/w/c/numeric/math/nan
So either the include is changed to
<cmath.h>
, either the prefixstd
should be removed.