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,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.129.97.67 with SMTP id v64mr14620206ywb.162.1498836874458; Fri, 30 Jun 2017 08:34:34 -0700 (PDT) X-Received: by 10.36.82.8 with SMTP id d8mr346573itb.7.1498836874414; Fri, 30 Jun 2017 08:34:34 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!feeder.eternal-september.org!news.glorb.com!m54no1615199qtb.1!news-out.google.com!s132ni2715itb.0!nntp.google.com!v202no262713itb.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Fri, 30 Jun 2017 08:34:34 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=2003:c7:83c0:d405:3dda:1733:e43d:7354; posting-account=rmHyLAoAAADSQmMWJF0a_815Fdd96RDf NNTP-Posting-Host: 2003:c7:83c0:d405:3dda:1733:e43d:7354 References: User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <013cbb16-babe-44e8-b201-5d2afbca26b2@googlegroups.com> Subject: Re: Ada wikibook help needed (O-O) From: AdaMagica Injection-Date: Fri, 30 Jun 2017 15:34:34 +0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Xref: news.eternal-september.org comp.lang.ada:47235 Date: 2017-06-30T08:34:34-07:00 List-Id: Am Freitag, 30. Juni 2017 15:54:44 UTC+2 schrieb Norman Worth: > G.B. wrote: > > Hi all, > > > > for a number of years, the Wikibook subsection on O-O in Ada > > seems to have suffered from lack of clarity, according to a number > > of comments still present, a few written a number of years ago. > > > > Some here may say that this state of presentation is caused by > > Ada using type extension and so forth in the first place. > > But still, if the book does place Ada in contrast with C++, > > say, or explains Ada O-O, then it should be possible to > > precisely use Ada vocabulary to make readers profit by adding > > unmistakable carity. > > > > https://en.wikibooks.org/wiki/Ada_Programming/Object_Orientation > > > > If you have a moment, could you kindly substantiate whether or not, > > e.g., the following are absolutely and demonstrably correct and well p= ut? > > > > > > The page goes to some length to explain static dispatching > > vs. dynamic dispatching, but fails to introduce "dispatching" > > first, as a term, or to reference some suitable definition. > > Then, > > > > "A conversion to the class-wide type makes [components] visible again= ." > > > > Is "visible" correct? > > > > > > Is it correct to say =E2=80=9Cstatic call=E2=80=9D at all, other than w= hen waving hands, > > (not helpfully IMHO) in > > > > "within Op1, the first call to Op2 is therefore also a static call " > > > > where > > > > procedure Op1 (This: Root) is > > begin > > ... > > Op2 (This); -- not redispatching > > ... > > end Op1; > > > > The idea being that =E2=80=9Cstatic call=E2=80=9D is not really defined= in Ada AFAICT, > > other than to mean a call of a static function in a static expression. > > So, not the same thing as discussing O-O, or static binding, > > or dynamic dispatch. > > > > > > "In other OO languages, a method is either dispatching or not. > > In Ada, a routine is either _available_ for dispatching or not. " > > > > The wording of LRM N(28) seems to not be in line with the second > > of these statements. > > > > ... > I agree; this section is very poorly written from top to bottom. Others= =20 > have commented on Ada language technical problems with the article, but= =20 > the worst problems stem from its English structure. Most textbooks do a= =20 > far better job. We need to build the article from simple definitions=20 > and contexts through simple Ada constructs until we have explained the=20 > Ada philosophy for OOP and given adequate examples. It needn't be too=20 > complicated, but it should be complete. Here, even the definitions of=20 > OOP and OO design are unclear and do not follow the historical and=20 > common definitions. The section should be scrapped and rewritten, rather= =20 > than revised. I would tackle it, but I don't feel sufficiently=20 > experienced in Ada OOP to do so. I'm with you, I do not like the page's structure either. I wrote part of th= is, but I shied away from redoing the page from scratch. Part of this shiness stems from the fact that I have no idea how to structu= re the page. So I encourage you to lay out here the structure you would like. We, the Ad= a fans, can discuss it and fill the flesh to the bones. To the definitions of OO and especially OOP: There is no commonly accepted = definition, as far as I can see. Every language has its own nomenclature. A= class in Ada is very different from a class in Java or C++. C++'s methods = are primitive operations in Ada. And why should we follow the historical de= finitions going back to Simula?