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-Thread: 103376,9b7d3a51d0d8b6ee X-Google-Attributes: gid103376,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII Path: g2news1.google.com!postnews.google.com!33g2000yqm.googlegroups.com!not-for-mail From: Martin Newsgroups: comp.lang.ada Subject: Re: Extending discriminant types Date: Tue, 25 Nov 2008 02:37:51 -0800 (PST) Organization: http://groups.google.com Message-ID: <8e021577-260a-44e1-b765-4d81f6ba89df@33g2000yqm.googlegroups.com> References: <20081115101632.5f98c596@cube.tz.axivion.com> <20081122011825.5354d1c1@cube.tz.axivion.com> <4928ecad$0$32681$9b4e6d93@newsspool2.arcor-online.net> <648Wk.39330$_Y1.32087@bgtnsc05-news.ops.worldnet.att.net> <492a7d07$0$30236$9b4e6d93@newsspool1.arcor-online.net> NNTP-Posting-Host: 20.133.0.8 Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: posting.google.com 1227609472 25757 127.0.0.1 (25 Nov 2008 10:37:52 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: Tue, 25 Nov 2008 10:37:52 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: 33g2000yqm.googlegroups.com; posting-host=20.133.0.8; posting-account=g4n69woAAACHKbpceNrvOhHWViIbdQ9G User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9.0.4) Gecko/2008102920 Firefox/3.0.4,gzip(gfe),gzip(gfe) Xref: g2news1.google.com comp.lang.ada:2782 Date: 2008-11-25T02:37:51-08:00 List-Id: On Nov 24, 10:16=A0pm, a...@anon.org (anon) wrote: [snip] > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0-- Replacing T with Integer wi= ll still result in an error > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0-- for the 83 specs. Because B= ase is not an attribute > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0-- in Ada 83. > =A0 function "=3D" ( Left, Right : T'Base ) return Boolean ; That's not legal Ada83. Look at Appendix A: * P'BASE For a prefix P that denotes a type or subtype: This attribute denotes the base type of P. It is only allowed as the prefix of the name of another attribute: for example, P'BASE'FIRST. (See 3.3.3.) You can't ever use 'Base on its own in Ada83. Cheers -- Martin