This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch] cleanup: Wunused corefile.c
- From: Tom Tromey <tromey at redhat dot com>
- To: Aleksandar Ristovski <aristovski at qnx dot com>
- Cc: "gdb-patches\ at sourceware dot org" <gdb-patches at sourceware dot org>
- Date: Fri, 01 Feb 2013 12:25:43 -0700
- Subject: Re: [patch] cleanup: Wunused corefile.c
- References: <510AC74E.1010709@qnx.com> <87vcad5cf1.fsf@fleche.redhat.com> <510AD43E.3040405@qnx.com>
>>>>> "Aleksandar" == Aleksandar Ristovski <aristovski@qnx.com> writes:
Aleksandar> This is why I put a FIXME - intending to revisit and properly fix.
FIXME comments are just ignored in practice. IME, nobody ever fixes
them except as a side effect of what they were intending to do.
Aleksandar> But there are other cases where it is not about missing code, but
Aleksandar> e.g. conditional compilation. For example:
Yeah, in that case I am less sure.
Making the definition conditional might be ok.
Or it might be uglier than the occasional ATTRIBUTE_UNUSED.
I guess it depends on the case.
Aleksandar> However, I do not intend to push this very hard due to lack
Aleksandar> of time. I simply did a swipe over the code and made it
Aleksandar> compile with Wunused (without regressions) on
Aleksandar> x86_64-linux-gnu and wanted to contribute as much as I can
Aleksandar> without spending too much time on it.
I understand, but I think the hard part of this work is also the most
useful part. What I mean is that it is certainly valuable to get all
the simple cases fixed; but going through the trickier cases and writing
proper fixes is the real benefit of enabling this warning -- finding and
fixing real bugs. Making these warnings disappear is contrary to that.
Tom