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-Thread: 103376,227757d168eaa8a5 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news4.google.com!news.glorb.com!newsfeed00.sul.t-online.de!t-online.de!news-lei1.dfn.de!news-ham1.dfn.de!news.uni-hamburg.de!cs.tu-berlin.de!uni-duisburg.de!not-for-mail From: Georg Bauhaus Newsgroups: comp.lang.ada Subject: Re: A question re meaning/use of the "for ... use ..." Date: Wed, 8 Dec 2004 16:23:37 +0000 (UTC) Organization: GMUGHDU Message-ID: References: <41b3291e$0$44072$5fc3050@dreader2.news.tiscali.nl> <41b6bc76$1_1@baen1673807.greenlnk.net> NNTP-Posting-Host: l1-hrz.uni-duisburg.de X-Trace: a1-hrz.uni-duisburg.de 1102523017 3963 134.91.1.34 (8 Dec 2004 16:23:37 GMT) X-Complaints-To: usenet@news.uni-duisburg.de NNTP-Posting-Date: Wed, 8 Dec 2004 16:23:37 +0000 (UTC) User-Agent: tin/1.5.8-20010221 ("Blue Water") (UNIX) (HP-UX/B.11.00 (9000/800)) Xref: g2news1.google.com comp.lang.ada:6847 Date: 2004-12-08T16:23:37+00:00 List-Id: Martin Dowie wrote: : Clearly this is a lot less important than extra libraries, interfaces, etc. : but I have wondered this before myself and I think it would improve program : readability quite a bit. As for "when expression" everywhere, I do not think so. In exit when expression it is quite clear what is going to happen when expression is true. In return expression when expression the second expression might be off the radar when you read return expression. In fact, I've used this kind of syntactical arrangement a lot in Perl programs and was told not to do so. I think this was good advice. Reading "return E when E" requires a lot of "conditional shuffling" and "reading back". Worse, you could write if expression then return expression when expression ending up with a well hidden multiple exit problem due to TIMTOWTDI. (I hope I have not repeated the Ada comments arguments.) -- Georg