missing gcc C comp

Aaron Sosnick aaron@caxton.com
Thu Nov 11 12:12:00 GMT 1999


Once upon a time gcc had some combination of command line options that
caused it to make noise when C code ignored the return value of a function:


extern int foo();

int main() {
    foo();  /* gcc could be made to moan about the ignored return value */
    exit(1);
}


It could, of course, be annoying when moaning about ignoring the
return of value of fprintf and other such functions whose
return values you had no use for.

Nonetheless, I liked having the option around.

Does anybody know what happened to this warning?

In the latest versions (2.95.x, 2.8.x) no amount of twiddling with the
various -W flags seems to be able to make it complain.

Did it go away or am I just missing something.


More information about the Gcc-help mailing list