At the risk of boring everyone:

There are a couple of reasons that we have to type "int main( ... )".  The 
biggest one is that way back in the early days of C there were no qualifiers on 
functions, so it was just "main( ... )".  The int was implied, and you could 
not say "unsigned char main".

There were no prototypes and no declarations in the arguments, so main looked 
like this:

main( argc, argv )
        char *argv[];
{
        /* Some code. */
}

Note that argc is implied to be int.

-----Original Message-----
From: Linux on 390 Port [mailto:[EMAIL PROTECTED] Behalf Of Rob
van der Heij
Sent: Monday, October 10, 2005 8:42 AM
To: LINUX-390@VM.MARIST.EDU
Subject: Re: 2005-10-04 Recommended Linux on zSeries code drop to
developerWorks


On 10/10/05, Alan Altmark <[EMAIL PROTECTED]> wrote:

> If I understood correctly, the Linux return code cannot carry the full
> range of CP return codes as it can only have a value from 0-255 and no
> negative values.  Did I misunderstand?

Bummer. Why do we write 'int main( )'  then rather than 'char main( )'   ?

Rob
--
Rob van der Heij                  rvdheij @ gmail.com

----------------------------------------------------------------------
For LINUX-390 subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: INFO LINUX-390 or visit
http://www.marist.edu/htbin/wlvindex?LINUX-390

----------------------------------------------------------------------
For LINUX-390 subscribe / signoff / archive access instructions,
send email to [EMAIL PROTECTED] with the message: INFO LINUX-390 or visit
http://www.marist.edu/htbin/wlvindex?LINUX-390

Reply via email to