Path: utzoo!attcan!uunet!zaphod.mps.ohio-state.edu!uwm.edu!bionet!agate!linus!linus!sdimax2!jrv From: jrv@sdimax2.mitre.org (VanZandt) Newsgroups: comp.lang.c++ Subject: Re: Access to argc,argv outside main() ? Message-ID: <124738@linus.mitre.org> Date: 29 Oct 90 15:12:06 GMT References: <3101@zgdvda.zgdvda.uucp> Sender: usenet@linus.mitre.org Organization: The MITRE Corp., Bedford, MA Lines: 12 In article <3101@zgdvda.zgdvda.uucp> dingelde@zgdvda.zgdvda.uucp (Dennis Dingeldein) writes: >My objects need to access argc and argv coming from the command line. >Those values are undefined outside main. So, global defined objects >can`t access these values (Right?) . Turbo C++ defines the global variables _argv and _argc which have the same values as the variables argv and argc passed to main(). I ASSUME they are available even before main() gets called. (1) You might check whether g++ implements them too. (2) Maybe it has something equivalent. (3) If not, how about some GNU guru adding them? - Jim Van Zandt