Open jefftrull opened 3 years ago
std::abs needs either <cmath> or <cstdlib> but neither is included. This results in a particularly hairy ambiguous overload problem on some old versions of gcc.
std::abs
<cmath>
<cstdlib>
It also may be better to use std::fabs, which is intended for this use case
std::fabs
This stackoverflow answer was particularly helpful for me
std::abs
needs either<cmath>
or<cstdlib>
but neither is included. This results in a particularly hairy ambiguous overload problem on some old versions of gcc.It also may be better to use
std::fabs
, which is intended for this use case