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=-2.9 required=5.0 tests=BAYES_00,MAILING_LIST_MULTI autolearn=unavailable autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,f24b55bcdf15c088 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-03-06 16:14:03 PST Path: supernews.google.com!sn-xit-03!supernews.com!freenix!enst!enst.fr!not-for-mail From: "Robert C. Leif, Ph.D." Newsgroups: comp.lang.ada Subject: RE: Ada95 tutorials with sample code. Date: Tue, 6 Mar 2001 16:11:12 -0800 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="iso-8859-1" Content-Transfer-Encoding: 7bit X-Trace: avanie.enst.fr 983923925 96523 137.194.161.2 (7 Mar 2001 00:12:05 GMT) X-Complaints-To: usenet@enst.fr NNTP-Posting-Date: Wed, 7 Mar 2001 00:12:05 +0000 (UTC) To: Return-Path: X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2911.0) Importance: Normal In-Reply-To: <3AA48DE9.A0650F21@emw.ericsson.se> X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org X-Mailman-Version: 2.0 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: comp.lang.ada mail<->news gateway List-Unsubscribe: , List-Archive: Errors-To: comp.lang.ada-admin@ada.eu.org X-BeenThere: comp.lang.ada@ada.eu.org Xref: supernews.google.com comp.lang.ada:5486 Date: 2001-03-06T16:11:12-08:00 From: Bob Leif To: Sven Nilsson et al. In general, I agree that the excessive Use clauses can be a real pain when it comes to understanding or maintaining Ada source. I have suggested that a Table of Contents comment (annotation) before the package renames section and an End Table of Contents afterwards would be a much better way to communicate. I would also like and would pay a reasonable price for a an ASIS tool that undid the Use clauses. It could be named Pragma No_Use. -----Original Message----- From: comp.lang.ada-admin@ada.eu.org [mailto:comp.lang.ada-admin@ada.eu.org]On Behalf Of Sven Nilsson Sent: Monday, March 05, 2001 11:13 PM To: comp.lang.ada@ada.eu.org Subject: Re: Ada95 tutorials with sample code. I'm sorry if I disrupt this thread with a slightly off-topic question (which I'm sure has been discussed countless times before) BUT This use-thingy. Is it really ant good? I've only ever used Ada in HUGE projects with loads of people writing the code and I've found that the use-clause can be a real pain as it dosn't give you a clue as to where things are declared. Right now I'm teaching new arrivals about Ada 95 and I invariably tell them NOT to use the use-clause. Now, there're a lot of very clever and skilled people reading this news-group and I'd be interested in your feelings on "use". Is it a Do or Don't? Generally speaking? My Hello World would probably look something like this: -- "Hello, World" with Ada.Text_IO; procedure Hello_World is package Tio renames Ada.Text_IO; -- Rename common packages so I don't have to -- type in the whole thing every time I use it begin Tio.Put_Line("Howdy, World!"); -- Use Tio to access Ada.Text_IO end Hello_World; > -- "Hello, World!" program in Ada > > with Ada.Text_IO; > > use Ada.Text_IO; > procedure Hello_World is > -- null; > begin -- Hello_World > Put_Line (Item => "Hello, World!"); > end Hello_World; > -Sven