This is the mail archive of the
gdb-patches@sourceware.cygnus.com
mailing list for the GDB project.
Re: gdb/testsuite/gdb.code/*.exp
- To: ac131313 at cygnus dot com, gdb-patches at sourceware dot cygnus dot com
- Subject: Re: gdb/testsuite/gdb.code/*.exp
- From: Michael Elizabeth Chastain <chastain at cygnus dot com>
- Date: Thu, 23 Dec 1999 15:12:42 -0800 (PST)
I did something like that in the Linux kernel.
I wrote a small perl script invoked by "make checkconfig". The script
looks for source files that test CONFIG_* variables without #including
"<linux/config.h>" first. (Due to the vagaries of the C standard,
this usage silently does an unexpected thing).
Every so often, somebody runs "make checkconfig" and sends results to
Linus.
I think the basic idea, running some kind of script to issue more warnings,
is good. The script has to be conservative, though: if it flags false
positives, it quickly either becomes worthless or people come to avoid
anything that upsets the script.
It's analagous to adding new warnings to "gcc", but because it's a separate
script, it gets to use more site-specific rules.
Michael