This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Unused macros warning?


>>>>> "Neil" == Neil Booth <neil@daikokuya.co.uk> writes:

 Neil> I made a local modification to cpplib so that, if -Wunused, it
 Neil> reports all macros defined in the main file that are unused, or
 Neil> unused before being #undef-ed.

 Neil> Might this be a useful addition to mainline?  It shouldn't be
 Neil> in -Wall, as it involves a slightly expensive hashtable walk at
 Neil> the end of preprocessing which most users wouldn't want to pay
 Neil> for, but could be enabled with the front ends' -Wunused, say.

I assume you would also add a -Wunused-macros so you can separately
enable or disable this.  The latter is important if I want the
existing unused warnings but not this new one.

	 paul


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]