No, I see no reason for this. Others mentioned that it is possible to have platforms with a "negative zero", but such a negative zero can never be created by this expression, so it is useless.
The relevant paragraph in the C standard is 6.2.6.2 p3, my emphasis is:
If the implementation supports negative zeros, they should only be generated by:
- operators &, |, ^, ~, <<and โ with operands that produce such a value;
- operators +, -, *, / and% , where one operand is negative zero , and the result is zero;
- connection based on the above cases.
To create a negative zero on such a platform, you could use, for example, ~INT_MAX , but that would not be zero for other views, so the code would not be very portable.
source share