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=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,60e2922351e0e780 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-11-06 09:41:00 PST Path: archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newshub.sdsu.edu!cyclone.bc.net!news.uunet.ca!nf3.bellglobal.com!nf1.bellglobal.com!nf2.bellglobal.com!news20.bellglobal.com.POSTED!not-for-mail From: "Warren W. Gay VE3WWG" User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax) X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Clause "with and use" References: <3FA2CDCB.500F4AF0@fakeaddress.nil> <3FA3B412.AF3BEB96@fakeaddress.nil> <3FA6D275.924D5750@fakeaddress.nil> <1067951806.729117@master.nyc.kbcfp.com> <1068123815.335508@master.nyc.kbcfp.com> In-Reply-To: <1068123815.335508@master.nyc.kbcfp.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Message-ID: Date: Thu, 06 Nov 2003 12:26:28 -0500 NNTP-Posting-Host: 198.96.223.163 X-Complaints-To: abuse@sympatico.ca X-Trace: news20.bellglobal.com 1068139555 198.96.223.163 (Thu, 06 Nov 2003 12:25:55 EST) NNTP-Posting-Date: Thu, 06 Nov 2003 12:25:55 EST Organization: Bell Sympatico Xref: archiver1.google.com comp.lang.ada:2158 Date: 2003-11-06T12:26:28-05:00 List-Id: Hyman Rosen wrote: > Preben Randhol wrote: > >> So what do you relaly mean? > > I mean that an Ada program can contain > with a, b, c, d; > use a, b, c, d; > and it may also contain > with a, b, c, d; > use a, c, d; > See > for an example of the latter form. It contains > with ADA.TEXT_IO, ADA.CALENDAR, ADA.CHARACTERS.LATIN_1; > use ADA.TEXT_IO, ADA.CHARACTERS.LATIN_1; > > So upon seeing a with/use pair, I have to read it carefully to > see if the two lists are the same, and if they are not, try to > figure out why that may be. The other problem is that you don't always want to "use" every with. Consider: WITH ADA.STRINGS.FIXED; I may just want: USE ADA.STRINGS.FIXED; but not: USE ADA.STRINGS; Why? Because ADA.STRINGS.LEFT may conflict with some other definition I have in my code named LEFT. However, I may want to use ADA.STRINGS.FIXED.INDEX() for some reason, perhaps frequently so, that a USE statement makes sense within the block where it is referenced. Where I need ADA.STRINGS.LEFT, I can use the fully qualified path to it. -- Warren W. Gay VE3WWG http://home.cogeco.ca/~ve3wwg