From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.4 required=5.0 tests=AC_FROM_MANY_DOTS,BAYES_00 autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,f954bcd9ffa6c26c X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-01-18 06:36:04 PST Path: supernews.google.com!sn-xit-03!supernews.com!logbridge.uoregon.edu!newsfeed.direct.ca!look.ca!newsfeed1.earthlink.net!newsfeed2.earthlink.net!newsfeed.earthlink.net!news.mindspring.net!not-for-mail From: Marin David Condic Newsgroups: comp.lang.ada Subject: Re: Gnat 3.13p: Command_Name RM A.15 Date: Thu, 18 Jan 2001 09:32:38 -0500 Organization: MindSpring Enterprises Message-ID: <3A66FE85.6770CBF6@acm.org> References: NNTP-Posting-Host: d1.56.b8.d5 Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Server-Date: 18 Jan 2001 14:34:26 GMT X-Mailer: Mozilla 4.07 [en] (WinNT; I) Xref: supernews.google.com comp.lang.ada:4154 Date: 2001-01-18T14:34:26+00:00 List-Id: The instances you cite probably aren't an issue to Ada because they don't execute an Ada program. However, you are right about the Command_Name not necessarily returning the name of a file. If you had defined a logical for your executable, there is no reason to think that the logical name would be parsed out to be the executable image filename. And if you did try to translate it back to a filename, you'd be into system calls and thus decreasing your portability. Still, as I pointed out in another post, perfect portability is nice, but not always essential. If your problem is simply making the same source work on two specific platforms with only one pair of compilers, then you might get the job done this way. Break those assumptions and you have no guarantee of portability. But to paraphrase a quote: "Portable Enough is not nearly so wonderful a thing as Perfectly Portable, but its Portable Enough!" :-) MDC Larry Kilgallen wrote: > ICertainly you are correct that this may not be applicable for all cases. > The assumption that the implementation-dependent Command_Name bears any > relationship to a file name would seem to be fraught with peril. I have > not used an Ada95 compiler on VMS, but I would expect something called > Command_Name to return the command I had typed, rather than the filename > of the executable image that implemented that command. Some typical commands > and images they execute are: -- ====================================================================== Marin David Condic - Quadrus Corporation - http://www.quadruscorp.com/ Send Replies To: m c o n d i c @ q u a d r u s c o r p . c o m Visit my web site at: http://www.mcondic.com/ "I'd trade it all for just a little more" -- Charles Montgomery Burns, [4F10] ======================================================================