[Bug c/53232] No warning for main() without a return statement with -std=c99
redi at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Fri May 4 14:34:00 GMT 2012
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53232
--- Comment #2 from Jonathan Wakely <redi at gcc dot gnu.org> 2012-05-04 14:33:53 UTC ---
(In reply to comment #1)
> Neither -Wmain warns about this... I think it is a bug, at least in the case of
> -Wmain.
Why? -Wmain checks the type of main, not whether it has a redundant 'return 0;'
as the last statement.
More information about the Gcc-bugs
mailing list