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

--- Comment #6 from thomas at habets dot se ---
The sequence point is a bit off topic, but I can't imagine that it's the
intention to warn about `f() & f()`.

Per gcc docs it's supposed to "Warn about code that may have undefined
semantics because of violations of sequence point rules in the C and C++
standards […] Programs whose behavior depends on this have undefined behavior".

I'm not a language lawyer, but I can't imagine that it's the intention to warn
about e.g. `printf("called with %f: %s", sqrt(2), strerror(errno));`. Nor does
it sound helpful to do so.

Nor `x = get_value() & admin_bits();`. There's just no wrong but technically
conforming way to miscompile that.

Reply via email to