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]

Non-void function not having an explicit value


If I have the following *simple* code.

int test()
{
}

int main()
{
}

I compile with -Wall, but GCC 4.0 only issues two warnings on int test(), but gives no warnings on int main(). I thought it should be an error for a non-void function not explicitly returning a value.



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