public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: n8tm@aol.comnojunk (Tim Prince)
To: help-gcc@gnu.org
Subject: Re: Newbie gcc question
Date: Sun, 12 Sep 1999 15:47:00 -0000	[thread overview]
Message-ID: <19990912184242.01175.00001288@ng-bg1.aol.com> (raw)
In-Reply-To: <zNVC3.6304$N77.506041@typ11.nn.bcandid.com>

>why gcc doesn't work with 'void'  but works with 'int'
>and '   ' ?

There must be something in the comp.lang.c FAQ on this; this is one of the
great gulfs between the Microsoft camp and the rest of the C world.  Most
environments where C programs run expect main() to return an int status code,
and getting this wrong is just as bad as it would be inside your program.  C++
gets even more wrought up about this; C has some historical loopholes where
failure to declare is made to default to int, of which this is one.  Speaking
as a Fortran programmer who has to work in environments which expect programs
to run like C, and has a great familiarity with undeclared things.
Tim Prince
tprince@computer.org

WARNING: multiple messages have this Message-ID
From: n8tm@aol.comnojunk (Tim Prince)
To: help-gcc@gnu.org
Subject: Re: Newbie gcc question
Date: Thu, 30 Sep 1999 23:56:00 -0000	[thread overview]
Message-ID: <19990912184242.01175.00001288@ng-bg1.aol.com> (raw)
Message-ID: <19990930235600.gYHm0V-E9Eh1WUyPTt-cm0H2xRxxuz_OIjX87n86WTQ@z> (raw)
In-Reply-To: <zNVC3.6304$N77.506041@typ11.nn.bcandid.com>

>why gcc doesn't work with 'void'  but works with 'int'
>and '   ' ?

There must be something in the comp.lang.c FAQ on this; this is one of the
great gulfs between the Microsoft camp and the rest of the C world.  Most
environments where C programs run expect main() to return an int status code,
and getting this wrong is just as bad as it would be inside your program.  C++
gets even more wrought up about this; C has some historical loopholes where
failure to declare is made to default to int, of which this is one.  Speaking
as a Fortran programmer who has to work in environments which expect programs
to run like C, and has a great familiarity with undeclared things.
Tim Prince
tprince@computer.org

WARNING: multiple messages have this Message-ID
From: n8tm@aol.comnojunk (Tim Prince)
To: help-gcc@gnu.org
Subject: Re: Newbie gcc question
Date: Fri, 01 Oct 1999 00:00:00 -0000	[thread overview]
Message-ID: <19990912184242.01175.00001288@ng-bg1.aol.com> (raw)
Message-ID: <19991001000000.5556sZcAk4zdANw7t01TpgdUDtlPhobfRva4B9labMQ@z> (raw)
In-Reply-To: <zNVC3.6304$N77.506041@typ11.nn.bcandid.com>

>why gcc doesn't work with 'void'  but works with 'int'
>and '   ' ?

There must be something in the comp.lang.c FAQ on this; this is one of the
great gulfs between the Microsoft camp and the rest of the C world.  Most
environments where C programs run expect main() to return an int status code,
and getting this wrong is just as bad as it would be inside your program.  C++
gets even more wrought up about this; C has some historical loopholes where
failure to declare is made to default to int, of which this is one.  Speaking
as a Fortran programmer who has to work in environments which expect programs
to run like C, and has a great familiarity with undeclared things.
Tim Prince
tprince@computer.org

  reply	other threads:[~1999-09-12 15:47 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-09-12 15:32 Wayne Willson
1999-09-12 15:47 ` Tim Prince [this message]
1999-09-30 23:56   ` Tim Prince
1999-10-01  0:00   ` Tim Prince
1999-09-12 21:47 ` Chris Gregory
1999-09-30 23:56   ` Chris Gregory
1999-10-01  0:00   ` Chris Gregory
1999-09-30 23:56 ` Wayne Willson
1999-10-01  0:00 ` Wayne Willson
1999-10-13 15:54 newbie " Maggie Owens
1999-10-13 16:09 ` Matthew Majka
1999-10-14  0:05   ` Johan Nilson
1999-10-14  9:58     ` Matthew Majka
1999-10-31 13:57       ` Matthew Majka
1999-10-31 13:57     ` Johan Nilson
1999-10-31 13:57   ` Matthew Majka
1999-10-13 22:53 ` Konstantinos Adamopoulos
1999-10-31 13:57   ` Konstantinos Adamopoulos
1999-10-14 12:25 ` Maggie Owens
1999-10-31 13:57   ` Maggie Owens
1999-10-31 13:57 ` Maggie Owens
2002-04-29 18:21 Michael Kahle
2002-04-29 18:45 ` Claudio Bley
2002-04-29 19:48 ` Andrea 'Fyre Wyzard' Bocci
2002-04-29 19:51 Michael Kahle
2002-04-29 20:14 Michael Kahle

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=19990912184242.01175.00001288@ng-bg1.aol.com \
    --to=n8tm@aol.comnojunk \
    --cc=help-gcc@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).