Path: utzoo!utgpu!jarvis.csri.toronto.edu!dgp.toronto.edu!flaps Newsgroups: comp.lang.c From: flaps@dgp.toronto.edu (Alan J Rosenthal) Subject: Re: entry at other than main (was: want to know) Message-ID: <1989Sep3.233033.6546@jarvis.csri.toronto.edu> References: <182@sunquest.UUCP> <14269@haddock.ima.isc.com> <1496@l.cc.purdue.edu> <1701@crdgw1.crd.ge.com> <2538@trantor.harris-atd.com> <10760@smoke.BRL.MIL> <2563@trantor.harris-atd.com> <10781@smoke.BRL.MIL> <2634@trantor.harris-atd.com> <14506@haddock.ima.isc.co <2643@trantor.harris-atd.com> Date: 4 Sep 89 03:30:34 GMT bbadger@x102c.harris-atd.com (Badger BA 64810) writes: >I just wonder whether it [main() being the entry point] deserves a secure >place in the standard, because I can't see that the language would be any >worse off without it. Without it, you cannot write Hello, world portably! "int main() { printf("Hello, world\n"); return(0); }" ?? No, it might not get run. Remember that the purpose of the standard is to allow the writing of portable programs. That means that someone else can recompile your program somewhere else without editing it and it will work and do the same thing it did for you. The standard is not merely a guideline as to what is a good C implementation. ajr