Bug#625357: jigit: ftbfs with gcc-4.6 -Werror
Steve McIntyre wrote:
> I'll remove the -Werror to stop gcc breaking the build here, but I
> definitely believe that gcc is doing the wrong thing here.
> Technically, yes - the variables are set but unused. However, this is
> a far higher level of pedantry than is warranted for -Wall.
The -Wall option has implied -Wunused-variable for a very long time;
the idea as I understand it was to detect dead code which might be an
indicator for other problems (typos or planned functionality that was
left out) and which is distracting. As I understand it, the only
reason -Wunused-but-set-variable did not exist until recently was a
small accident of implementation, that technically "x = 5;" is an
expression that evaluates "x".
I believe the best way to avoid breaking the build is to simply not use
-Werror on autobuilders. I would like to teach autobuilders to send
warnings by email to interested maintainers so maintainers could get the
benefit of notification without making the release team and toolchain
maintainers' lives more difficult; would you be interested in that?
Thanks and hope that helps,