On 10/25/2016 06:38 PM, Dominik Vogt wrote:
Right. A solution must disable the warnings on any compilers and
versions the developers use, and not break compilation anywhere.
The way I generally do it is check for the compiler, and then define a
macro for gcc and for clang using those attributes. Admittedly, that
works, because for the stuff I work on, those two are all that is
expected to be ever used; something that probably cannot be said about fvwm.
In the end, this mail (and the one from yesterday) are outdated anyway
because I see you already found another solution via the
SUPPRESSED_UNUSED_VAR_WARNING macro, so disregard my comments.
But, since I'm curious: that macro doesn't have the problem of
potentially masking warnings about using uninitialized variables? I
guess the important difference is that you only use , not x itself any
more? Still, that's interesting.
Florian