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,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 2002:a5e:9505:: with SMTP id r5-v6mr10057582ioj.134.1535883067109; Sun, 02 Sep 2018 03:11:07 -0700 (PDT) X-Received: by 2002:aca:5557:: with SMTP id j84-v6mr216680oib.3.1535883066991; Sun, 02 Sep 2018 03:11:06 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!feeder.eternal-september.org!news.uzoreto.com!weretis.net!feeder6.news.weretis.net!feeder.usenetexpress.com!feeder-in1.iad1.usenetexpress.com!border1.nntp.dca1.giganews.com!nntp.giganews.com!g24-v6no3019989iti.0!news-out.google.com!c63-v6ni4638ith.0!nntp.google.com!w19-v6no2978489itb.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Sun, 2 Sep 2018 03:11:06 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=80.139.100.162; posting-account=rmHyLAoAAADSQmMWJF0a_815Fdd96RDf NNTP-Posting-Host: 80.139.100.162 References: <309225242.556906218.575482.laguest-archeia.com@nntp.aioe.org><2145221813.556924687.162377.laguest-archeia.com@nntp.aioe.org><0001HW.213464550E84375C70000C7DB2CF@news.individual.net> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <849e14d4-5790-4951-be18-bc2fa8561051@googlegroups.com> Subject: Re: Studying and Maintaining GNAT, Is There Any Interest in a New Group? From: AdaMagica Injection-Date: Sun, 02 Sep 2018 10:11:07 +0000 Content-Type: text/plain; charset="UTF-8" Xref: reader02.eternal-september.org comp.lang.ada:54311 Date: 2018-09-02T03:11:06-07:00 List-Id: Am Samstag, 1. September 2018 00:51:42 UTC+2 schrieb Randy Brukardt: > Similarly, in Ada 2012: > Ren1 : Natural renames Func(1); -- Legal. > Ren2 : Natural renames Natural'(Func(1)); -- Legal. > Ren3 : Natural renames Natural(Func(1)); -- Illegal!!! > > At least Ada 2020 will fix this one. But try this: > Ren4 : Boolean renames Boolean'(A and B); -- Legal. > Ren5 : Boolean renames Boolean'(A and then B); -- Illegal. > Ren6 : Boolean renames "and"(A, B); -- Legal. > Ren7 : Boolean renames A and B; -- Illegal. Ahem, perhaps my Gnat 2018 is not correct, but it rejects only Ren7, which is an expression, and that cannot be renamed according to syntax. 3.3(2) defines objects. (BTW: Shouldn't the term object here be in italics?) Ren2 is a qualified expression with an object as operand. OK Ren3 is a type conversion of an object, which is a name. A type conversion is not an object. So Gnat is wrong? Ren4 and Ren5 both rename a qualified expression, but neither operand in an object. So Gnat is wrong again? > Anyone who claims they understand what can and cannot be renamed intuitively > is a liar. :-) True