When compiling for x86, compiler errors out since call to function abs() is ambiguous. Current workaround is to cast args in abs() as double for the x86 build. The compiler for the x86 build uses include -DWINDOWS which is used with #ifdef to create a separate call to abs() for x86 only. For native roboRIO builds abs() is left untouched.
When compiling for x86, compiler errors out since call to function abs() is ambiguous. Current workaround is to cast args in abs() as double for the x86 build. The compiler for the x86 build uses include -DWINDOWS which is used with #ifdef to create a separate call to abs() for x86 only. For native roboRIO builds abs() is left untouched.
https://github.com/REVrobotics/2m-Distance-Sensor/blob/8fa66c30369ccdbc9248534a32b1970a51ab8716/src/main/native/cpp/core/src/vl53l0x_api_core.c#L1835