This is the mail archive of the gcc-patches@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: [PATCH] Loop bug generates invalid code on s390


Ulrich Weigand <weigand@i1.informatik.uni-erlangen.de> writes:

> Jakub Jelinek wrote:
>
>> #ifdef DEFAULT_MAIN_RETURN
>>           /* Make it so that `main' always returns success by default.  */
>>           DEFAULT_MAIN_RETURN;
>> #else
>
> Hmmm.  For some reason s390.h defines DEFAULT_MAIN_RETURN.
> I wonder what the purpose of that was ...

I have been thinking that we should add this implicit return 0 always,
not just in C99 mode; this would allow DEFAULT_MAIN_RETURN to be
removed.  Except that the front end should then warn in C89 mode about
the lack of an explicit return, and I don't know how to do that.

zw


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