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 Path: g2news2.google.com!news3.google.com!proxad.net!feeder1-2.proxad.net!usenet-fr.net!club-internet.fr!feedme-small.clubint.net!nuzba.szn.dk!news.jacob-sparre.dk!pnx.dk!not-for-mail From: "Randy Brukardt" Newsgroups: comp.lang.ada Subject: Re: Gem 39 - compiler specific? Date: Thu, 3 Sep 2009 16:53:58 -0500 Organization: Jacob Sparre Andersen Message-ID: References: <9e0bbbcd-260f-48ed-8043-d6280c633e85@h3g2000yqa.googlegroups.com> <19268dbw82hf4.aii8as09aapk.dlg@40tude.net> NNTP-Posting-Host: static-69-95-181-76.mad.choiceone.net X-Trace: munin.nbi.dk 1252014916 26835 69.95.181.76 (3 Sep 2009 21:55:16 GMT) X-Complaints-To: news@jacob-sparre.dk NNTP-Posting-Date: Thu, 3 Sep 2009 21:55:16 +0000 (UTC) X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2900.5512 X-RFC2646: Format=Flowed; Original X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.5579 Xref: g2news2.google.com comp.lang.ada:8137 Date: 2009-09-03T16:53:58-05:00 List-Id: "Dmitry A. Kazakov" wrote in message news:19268dbw82hf4.aii8as09aapk.dlg@40tude.net... > On Wed, 2 Sep 2009 18:20:36 -0500, Randy Brukardt wrote: ... >> (As an aside, this technique could not work in Janus/Ada if Buffer was an >> unconstrained array: 'Address of an unconstrained array points at the >> array >> descriptor, not the data. > > It must point to the first array element 13.3(14). BTW, it is interesting > where it should point when the array is empty. The word in 13.3(14) is "should", not "must" (a word that is not allowed in Standards anyway). Specifically, 13.3(14) is Implementation Advice. There is no requirement in Ada to follow Implementation Advice, the only requirement is to document when you don't. That is, an Ada compiler's (formal) correctness cannot depend on Implementation Advice. What Janus/Ada does here is OK (but not recommended of course). Randy.