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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,ace3fca092a457cd X-Google-Attributes: gid103376,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news2.google.com!news.glorb.com!wn11feed!worldnet.att.net!bgtnsc05-news.ops.worldnet.att.net.POSTED!53ab2750!not-for-mail Newsgroups: comp.lang.ada From: anon@anon.org (anon) Subject: Re: Unary operator after binary operator: legal or not? => Illegal Reply-To: anon@anon.org (anon) References: <1185927237.362545.195380@d30g2000prg.googlegroups.com> X-Newsreader: IBM NewsReader/2 2.0 Message-ID: Date: Wed, 01 Aug 2007 06:20:34 GMT NNTP-Posting-Host: 12.64.18.203 X-Complaints-To: abuse@worldnet.att.net X-Trace: bgtnsc05-news.ops.worldnet.att.net 1185949234 12.64.18.203 (Wed, 01 Aug 2007 06:20:34 GMT) NNTP-Posting-Date: Wed, 01 Aug 2007 06:20:34 GMT Organization: AT&T Worldnet Xref: g2news2.google.com comp.lang.ada:1307 Date: 2007-08-01T06:20:34+00:00 List-Id: My Typo! Or was I too tied and hungry to see them! The Final word comes from Ada LRM 4.5.1 ( 17 ). Examples that the Ada Committee gave us. Y**(-3) -- parentheses are necessary This is defined in 83, 95 and 2005 LRM. Which makes it LAW! To most languages the parentheses are not required. Actually some languages even define the -3 as a numeric_literal. But this difference is what makes Ada a pain for some and a delight for others. But since the expression option is define as "(expression)" instead of "( expression )" I chose to define the parentheses to denote to use the BNF expression instead of the definition found in LRM 4.4 ( 1 ). Now, If the clause was "( expression )" which this clearly denotes that you must have a left parenthese followed by the expression which is followed by a right parenthese. And I would have agree with you earlier! But with the example stated in the LRM I can not argue. So, I Stand corrected! As for why I go by "Anon" that my business! In <1185927237.362545.195380@d30g2000prg.googlegroups.com>, Adam Beneschan writes: >On Jul 31, 4:22 pm, a...@anon.org (anon) wrote: > >> Ada LRM 4.4 ( 6 ) => factor ::= primary >> >> +Right >> -7 >> >> Ada LRM 4.4 ( 7 ) => primary ::= numeric_literal | .. | (expression) >> >> +Right => is defined as an expression >> -7 => is defined as an expression > >What happened to those nice parentheses around "expression" that the >above syntax rule requires? Did you think they were there in the RM >just for decoration? > >No wonder you won't post using your real name. > > -- Adam >