On 8 October 2015 at 01:26, Matteo Bruni mbruni@codeweavers.com wrote:
Clang on OS X complains about calling abs() on an unsigned value and I think it has a point since technically the unsigned to signed conversion is implementation-dependent when the value can't be represented in the signed integer type (i.e. for the "negative" numbers).
...and I don't suppose you accidentally compiled with -Wpedantic. The warning isn't wrong, but it's not terribly useful either. On two's complement systems (i.e., anything relevant) the reasonable thing to do is also the correct thing. This function exists in other places as well, of course.