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

--- Comment #6 from Viktor Ostashevskyi <ostash at ostash dot kiev.ua> ---
(In reply to Marek Polacek from comment #5)
> Yes, because we'd have to analyze the body of the function to see that it
> does not return one of the parameters, which often we can't do.
> 
> There will be an attribute soon to suppress that warning.

I'm wondering whether this diagnostics should be in -Wall or -Wextra at all.
It is assumed that diagnostics in -Wall or -Wextra generally "works".

Here, diagnostics clearly fails on simplest case and I don't think marking huge
codebase with some attribute is a proper solution...

Reply via email to