comment bogus main warning even with -Wno-main.

This commit is contained in:
mrg 1998-03-30 17:06:33 +00:00
parent 34c4557d93
commit a057e5253b

View File

@ -7022,6 +7022,7 @@ finish_function (nested)
if (TYPE_MAIN_VARIANT (TREE_TYPE (TREE_TYPE (fndecl))) if (TYPE_MAIN_VARIANT (TREE_TYPE (TREE_TYPE (fndecl)))
!= integer_type_node) != integer_type_node)
{ {
#ifndef __NetBSD__
/* You would expect the sense of this test to be the other way /* You would expect the sense of this test to be the other way
around, but if warn_main is set, we will already have warned, around, but if warn_main is set, we will already have warned,
so this would be a duplicate. This is the warning you get so this would be a duplicate. This is the warning you get
@ -7030,6 +7031,7 @@ finish_function (nested)
usual. */ usual. */
if (! warn_main) if (! warn_main)
pedwarn_with_decl (fndecl, "return type of `%s' is not `int'"); pedwarn_with_decl (fndecl, "return type of `%s' is not `int'");
#endif
} }
else else
{ {