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,5095dad989e89e23 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2000-12-13 07:03:59 PST Path: supernews.google.com!sn-xit-02!supernews.com!isdnet!newsfeed.icl.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!blackbush.xlink.net!rz.uni-karlsruhe.de!news.uni-stuttgart.de!cert.uni-stuttgart.de!not-for-mail From: Florian Weimer Newsgroups: comp.lang.ada Subject: Re: Does a null pointer always raise Constraint_Error? Date: 13 Dec 2000 15:58:14 +0100 Organization: RUS-CERT, University of Stuttgart, Germany Sender: rusfw@mercury.rus.uni-stuttgart.de Message-ID: References: <9074fi$93b$1@nnrp1.deja.com> <3A3253B1.AD8F32CF@ebox.tninet.se> <90u1vi$uah$1@nnrp1.deja.com> <90ukfm$c4p$1@nnrp1.deja.com> <3A36511D.973D82BD@nowhere.com> <916gsr$e6e$1@nnrp1.deja.com> NNTP-Posting-Host: mercury.rus.uni-stuttgart.de Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: hornet.rus.uni-stuttgart.de 976719783 4035 129.69.1.226 (13 Dec 2000 15:03:03 GMT) X-Complaints-To: abuse@cert.uni-stuttgart.de NNTP-Posting-Date: Wed, 13 Dec 2000 15:03:03 +0000 (UTC) User-Agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7 Xref: supernews.google.com comp.lang.ada:3060 Date: 2000-12-13T15:58:14+01:00 List-Id: lutz@iks-jena.de (Lutz Donnerhacke) writes: > * Ken Garlington wrote: > >"Lutz Donnerhacke" wrote in message > >: * Robert Dewar wrote: > >: [access to empty arrays represent as Null (System.Address)] > >: > subtype n is string (1 .. 0); > >: > type np is access n; > >: > a, b : np; > >: > > >: > if a.all = b.all then ... > >: > > >: >it is a common compiler bug to translate this as > >: > > >: > for j in n'range loop > >: > if a.all (j) = b.all (j) .... > >: > > >: >and the null loop causes no checks to be made :-) > Possible, but irrelevant IMHO. Two empty arrays of the same component type > are equal per definition. There a two language-defined checks involved prior to the array comparison. However, 11.6(5) seems to permit the omission of these checks, but I'm not sure about that.