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,79bbf7e359159d0d X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-04-11 14:58:06 PST Path: supernews.google.com!sn-xit-03!supernews.com!logbridge.uoregon.edu!news.maxwell.syr.edu!wn1feed!worldnet.att.net!135.173.83.71!wnfilter1!worldnet-localpost!bgtnsc05-news.ops.worldnet.att.net.POSTED!not-for-mail Message-ID: <3AD4D3C2.E45751D9@worldnet.att.net> From: James Rogers X-Mailer: Mozilla 4.76 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: newbie can't get exceptions to work! References: <25%y6.2364$jz.201607@www.newsranger.com> <3ACDB29E.45B91316@earthlink.net> <3AD2788C.7F2BAFA3@worldnet.att.net> <9b1oqv$ikb$2@taliesin.netcom.net.uk> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: Wed, 11 Apr 2001 21:57:17 GMT NNTP-Posting-Host: 12.74.129.224 X-Complaints-To: abuse@worldnet.att.net X-Trace: bgtnsc05-news.ops.worldnet.att.net 987026237 12.74.129.224 (Wed, 11 Apr 2001 21:57:17 GMT) NNTP-Posting-Date: Wed, 11 Apr 2001 21:57:17 GMT Organization: AT&T Worldnet Xref: supernews.google.com comp.lang.ada:6791 Date: 2001-04-11T21:57:17+00:00 List-Id: Ayende Rahien wrote: > Brian Rogoff suggested this: > procedure P(){ > } P; > > if (condition) { > } if; > > I think it has the best of both worlds. Now why must we begin to place boolean expressions inside parens? According to the logic used to defend [] versus () for arrays, doesn't this make an "if" statement look like a function call followed by a code block? Also, the supposed virtues of "{}" (imho) fade when you need to add a label to the closing brace. You now manage to save exactly two characters (en), but you must add an additional semicolon. In C, C++, and Java you can entirely omit the "{}", making the "if" statement unbracketed. That is a bad practice in those languages. It should not be adopted in any other langauges. Another point of observation concerning "{}". Look at the code for anonymous inner classes in Java. I am not convinced that curly braces are better than Ada's "begin/end" pairs. For those not familiar with Java anonymous inner class syntax I offer the following example: this.addWindowListener( new WindowAdapter() { public void windowClosed(WindowEvent e) { System.exit(0); } }); Jim Rogers Colorado Springs, Colorado USA