https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68971

--- Comment #3 from Martin Sebor <msebor at gcc dot gnu.org> ---
Yes, the example in footnote is valid because the left operand of the OR
expression is a constant expression with a non-zero value and so the right
operand is not evaluated (even at translation time).

__builtin_mul_overflow, OTOH, is not a constant expression, and so the
multiplication expression may be evaluated (and is allowed to be evaluated at
compile time) and the warning is, IMO, justified.

Reply via email to