This is the mail archive of the gcc-help@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: How to ignore Wall errors for a portion of code


Joezac Zachariah wrote:
Hi,

Thanks for your fast response. I am not sure whether my query was clear. I am using 'make' to compile the code and I am passing -Wall -Werror options. My requirement is that the Wall checks need to be done only on a portion of the code in a given '.c' file and not on the complete file. Is there a way or a Wall option with which I could switch the -Wall check 'off' for a portion of the file?

Sorry, I missed that. We invoke scripts from make which split functions where we want different compile options, then (if using gnu ld) recombine the .o files by ld -o bigfile.o -r split*.o (an old HPUX style thing). Our source files have style which permits reliable automatic splitting by function. Of course, this disables -finline-functions, so we have options to not split named files.


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