https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80138
--- Comment #4 from Richard Biener ---
I think that including -Wstrict-overflow in -Wall is a mistake given it is a
warning that assumes you assume signed overflow wraps and then tells you the
points where the compiler assumed otherwise.
But now
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80138
--- Comment #3 from Julien Pommier ---
I agree spurious was not the right wording, sorry for that. However it took me
quite a lot of time to understand and to find out which function was
responsible for the warning in my original code, which was
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80138
--- Comment #2 from Marc Glisse ---
It isn't spurious. Of little use and unwanted, yes. It is telling you that the
compiler assumed that your code was correct, that can hardly be wrong...
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80138
--- Comment #1 from Andrew Pinski ---
So the reason why it disappears with: "(w >= y) && (w < y+h)" is that GCC has
only one bit to say if we should not warn again on an expression and using ()
causes that bit to be set :). GCC needs more bits