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.3 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,990196a3d5e5eb5e X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-04-08 20:57:03 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!deine.net!freenix!enst!enst.fr!not-for-mail From: "Steven Deller" Newsgroups: comp.lang.ada Subject: RE: Child packages question Date: Mon, 8 Apr 2002 22:54:50 -0400 Organization: ENST, France Sender: comp.lang.ada-admin@ada.eu.org Message-ID: Reply-To: comp.lang.ada@ada.eu.org NNTP-Posting-Host: marvin.enst.fr Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: avanie.enst.fr 1018324623 69184 137.194.161.2 (9 Apr 2002 03:57:03 GMT) X-Complaints-To: usenet@enst.fr NNTP-Posting-Date: Tue, 9 Apr 2002 03:57:03 +0000 (UTC) Return-Path: X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook, Build 10.0.2627 Importance: Normal In-Reply-To: <3CB24F38.2D03C71A@myob.com> X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org X-Mailman-Version: 2.0.8 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: comp.lang.ada mail<->news gateway List-Unsubscribe: , Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org Xref: archiver1.google.com comp.lang.ada:22252 Date: 2002-04-08T22:54:50-04:00 Nice example. The second commented item (that you want to uncomment and see a complaint) should read: -- Car.Engine.Pump_More_Gas ; not -- Car.Engine.Accelerate; Of course a compiler will complain about either, but I believe the germane complaint (regarding private package) would occur for the first. Regards, Steve > -----Original Message----- > From: comp.lang.ada-admin@ada.eu.org > [mailto:comp.lang.ada-admin@ada.eu.org] On Behalf Of sk > Sent: Monday, April 08, 2002 10:17 PM > To: comp.lang.ada@ada.eu.org > Subject: Re: Child packages question > > > Hi, > > ----------------------------------------------------- > -- file1 : car.ads > package Car is > > procedure Accelerate; > > end Car; > > ----------------------------------------------------- > -- file2 : car.ads > with Car.Engine; > > package body Car is > > procedure Accelerate is > begin > Car.Engine.Pump_More_Gas; > end Accelerate; > > end Car; > > ----------------------------------------------------- > -- file2 : car-engine.ads > private package Car.Engine is > > procedure Pump_More_Gas; > > end Car.Engine; > > ----------------------------------------------------- > -- file2 : car-engine.adb > package body Car.Engine is > > procedure Pump_More_Gas is > begin > null; > end Pump_More_Gas; > > end Car.Engine; > > ----------------------------------------------------- > -- file2 : Mario_Andretti.adb > with Car; > --with Car.Engine; > > procedure Mario_Andretti is > > begin > Car.Accelerate; > > -- Car.Engine.Accelerate; > > end Mario_Andretti; > ----------------------------------------------------- > > Try uncommenting : > "with Car.Engine" > "Car.Engine.Accelerate" > > Compiler should complain :-) > > -- > ------------------------------------- > -- Merge vertically for real address > ------------------------------------- > s n p @ t . o > k i e k c c m > ------------------------------------- > _______________________________________________ > comp.lang.ada mailing list > comp.lang.ada@ada.eu.org > http://ada.eu.org/mailman/listinfo/comp.lang.ad> a >