On Sat, Jun 20, 2009 at 6:57 AM, H.J. Lu<hjl.to...@gmail.com> wrote: > On Sat, Jun 20, 2009 at 6:50 AM, James Dennett<james.denn...@gmail.com> wrote: > >>> I think it is a bad idea to include it in -Wall. You fixed 3 warnings in >>> gcc and I fixed 1 in binutils. If you have thousands of packages in C, >>> -Wall may generate hundreds of warnings. >> >> The same is true of any new -Wall warning that applies to existing >> code, but we must not let that stop us improving -Wall, even when >> existing code generates some (acceptable) level of false positives. > > The code is perfectly valid C.
Some code triggering this warning will be valid C, some will not. > This warning provides no additional > useful information which -Wuninitialized doesn't provide. Is that true? (That's a real question: is -Wjump-misses-init a subset of -Wuninitialized, in the obvious sense?) >>> It will make gcc 4.5.0 >>> unusable to those people. >> >> Can you justify that claim? How does getting warnings about >> questionable code constructs render a compiler "unusable"? >> > > If you have thousands of packages, investigate many false > positive errors may not be feasible on top of many other real > issues in gcc and packages. But investigating a small number is feasible, and it's not necessary to investigate them in order for the compiler to be usable. The only way diagostics can get stricter (and more useful) over time is if we accept that sometimes packages will generate new warnings (and even new errors); overall, that leads to more progress and better code than freezing -Wall would. -- James