Path: utzoo!attcan!uunet!ginosko!aplcen!haven!adm!smoke!gwyn From: gwyn@smoke.BRL.MIL (Doug Gwyn) Newsgroups: comp.lang.c Subject: Re: want to know Message-ID: <10770@smoke.BRL.MIL> Date: 17 Aug 89 21:00:41 GMT References: <8487@bsu-cs.bsu.edu> <2980@solo9.cs.vu.nl> <182@sunquest.UUCP> <14269@haddock.ima.isc.com> <1496@l.cc.purdue.edu> <1701@crdgw1.crd.ge.com> <2538@trantor.harris-atd.com> <1989Aug16.203219.11825@cs.rochester.edu> <2549@trantor.harris-atd.com> Reply-To: gwyn@brl.arpa (Doug Gwyn) Organization: Ballistic Research Lab (BRL), APG, MD. Lines: 22 In article <2549@trantor.harris-atd.com> bbadger@x102c.harris-atd.com (Badger BA 64810) writes: >You use significant names for the files of your programs, why shouldn't you >use significant names for the main routines? main() certainly is a descriptive name for the role of that pseudo-function within a C application. The application within its invocation context has yet another, hopefully descriptive, name ("grep"?) or icon (smiling frog?) or whatever. >There really wouldn't be any much change to C. Even now, main() isn't >treated specially by the C compiler. Speak for yourself. The C compiler I use at home processes the main() pseudo-function differently from other functions, and in general any Standard-conforming implementation is going to have to give some degree of special treatment to main(), since it doesn't follow quite the same rules as normal C functions. The question has come up, can the main() function be invoked as a normal C function (i.e. recursively by the application). I think it is not guaranteed by the Standard; others think it is. This would be a good thing for X3J11 to address in the "interpretations" phase.