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 Path: border1.nntp.dca.giganews.com!nntp.giganews.com!usenet.blueworldhosting.com!feeder01.blueworldhosting.com!au2pb.net!feeder.erje.net!eu.feeder.erje.net!news.stack.nl!aioe.org!.POSTED!not-for-mail From: "Dmitry A. Kazakov" Newsgroups: comp.lang.ada Subject: Re: a new language, designed for safety ! Date: Fri, 13 Jun 2014 18:13:16 +0200 Organization: cbb software GmbH Message-ID: <1jbnzkhvtqyb5.1nij4i58gc12t.dlg@40tude.net> References: <1402308235.2520.153.camel@pascal.home.net> <85ioo9yukk.fsf@stephe-leake.org> <9qednXOIGNDuLQXORVn_vwA@giganews.com> <1872904482424209024.314619laguest-archeia.com@nntp.aioe.org> <810507a4-427e-42bb-a468-e5939a4470db@googlegroups.com> <9qbfr6yf0gnb.182y1qs9eigz4$.dlg@40tude.net> Reply-To: mailbox@dmitry-kazakov.de NNTP-Posting-Host: AuYlnUSfTZrfhAkRjyySpQ.user.speranza.aioe.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Complaints-To: abuse@aioe.org User-Agent: 40tude_Dialog/2.0.15.1 X-Notice: Filtered by postfilter v. 0.8.2 Xref: number.nntp.dca.giganews.com comp.lang.ada:186899 Date: 2014-06-13T18:13:16+02:00 List-Id: On Fri, 13 Jun 2014 09:55:52 -0600, Shark8 wrote: > On 13-Jun-14 02:36, Dmitry A. Kazakov wrote: >> Range should have been a proper type. > > That would have been nice. > >> A'Range should have been a primitive >> array interface operation. > > Doesn't its status as a attribute, automatically accessible to any > array-type, put it in a similar category? (IOW, what's wrong with it > being an attribute?) You cannot override and re-implement it: type Ordered_Container is ... and What?; overriding -- What interface? function Range (X : Ordered_Container) return Which type? Technically primitive operations could be treated as attributes the way they are as "record members": type T is tagged ...; function Foo (X : T) return Bar; X.Foo is legal, so make X'Foo legal as well. >From the language design POV all different syntaxes of subprogram call must be treated uniformly, which includes indexing, aggregates, attributes, members, prefix, postfix, infix, assignment sugars. -- Regards, Dmitry A. Kazakov http://www.dmitry-kazakov.de