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.9 required=5.0 tests=BAYES_00,FORGED_GMAIL_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Received: by 2002:a6b:b513:: with SMTP id e19-v6mr3109539iof.35.1532727281029; Fri, 27 Jul 2018 14:34:41 -0700 (PDT) X-Received: by 2002:aca:f495:: with SMTP id s143-v6mr165886oih.7.1532727280858; Fri, 27 Jul 2018 14:34:40 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!feeder.eternal-september.org!news.linkpendium.com!news.linkpendium.com!news.snarked.org!border2.nntp.dca1.giganews.com!nntp.giganews.com!d7-v6no2153711itj.0!news-out.google.com!k71-v6ni2424itk.0!nntp.google.com!d7-v6no2153709itj.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Fri, 27 Jul 2018 14:34:40 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=76.113.16.86; posting-account=lJ3JNwoAAAAQfH3VV9vttJLkThaxtTfC NNTP-Posting-Host: 76.113.16.86 References: <72ccb7fa-a9cb-42e6-8c29-3c06da281a45@googlegroups.com> <2212eb54-cb4a-446f-9cdf-287ef220e2c2@googlegroups.com> <1b5a58b2-65b7-4df8-80b5-03e208d249e1@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: Subject: Re: Ada Distilled by Richard Riehle From: Shark8 Injection-Date: Fri, 27 Jul 2018 21:34:41 +0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Xref: reader02.eternal-september.org comp.lang.ada:53990 Date: 2018-07-27T14:34:40-07:00 List-Id: On Friday, July 27, 2018 at 2:07:21 PM UTC-6, Dmitry A. Kazakov wrote: >=20 > Types algebra, yes. Most important type operations Ada lacks are: >=20 > - ad-hoc supertypes, > - interface inheritance, > - full MI, > - full MD Ad-hoc supertypes are, I think, a mistake. The value in SUBTYPE is that it = is a singular set of restrictions [possibly null] placed upon it's "superty= pe". What this means is that for every SUBTYPE S there's an application of = 'Base to get to the first subtype (Ada "TYPE") -- This means that the relat= ion of TYPE/SUBTYPE can be graphed as a tree; if we introduce ad-hoc supert= ypes, we lose this property and now have to contend with a full many-to-man= y possibility TYPE-network rather than TYPE-tree. And I fail to see how thi= s would be useful in-practice. (IOW, what is the real use-case? Does that u= se-case justify such an increase in complexity?) I'm in agreement with interface-inheritance, I think: IIRC, you're referrin= g to what is essentially my idea for "abstract interfaces" whereby we could= define Ada's type-system in terms of the stated hierarchy; as per this pic= ture: https://en.wikibooks.org/wiki/Ada_Programming/Type_System#The_Type_H= ierarchy -- exposing what is already fairly explicit in the LRM.=20 Multiple Inheritance -- I'm not sure this is a good idea at all. Looking at= C++ programmers and their experiences it seems to be more trouble than it'= s actually worth. (Interfaces aren't so bad, but can still conflict; Delphi= has the IMPLEMENTS keyword that can be used for both disambiguation as wel= l as delegation.) ...Why do you think Ada (or its successor) should have fu= ll MI? Multiple Dispatch -- This one I can see having more usability than Multiple= Inheritance.