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,34c2aa33b8bdb1a9 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-01-28 08:33:28 PST Path: archiver1.google.com!news1.google.com!sn-xit-02!supernews.com!newsfeed.direct.ca!look.ca!sfo2-feed1.news.digex.net!intermedia!news-out.spamkiller.net!propagator-la!news-in-la.newsfeeds.com!news-in.superfeed.net!news.cn99.com!fu-berlin.de!uni-berlin.de!b9978.pppool.DE!not-for-mail From: dmitry@elros.cbb-automation.de (Dmitry A. Kazakov) Newsgroups: comp.lang.ada Subject: Re: Sugestion to Multiple Inheritance Date: Mon, 28 Jan 2002 16:23:33 GMT Message-ID: <3c556f07.1368299@news.cis.dfn.de> References: <3C444B8D.70309@mail.com> <3c4e792f.2217296@News.CIS.DFN.DE> NNTP-Posting-Host: b9978.pppool.de (213.7.153.120) X-Trace: fu-berlin.de 1012234915 39056285 213.7.153.120 (16 [77047]) X-Newsreader: Forte Free Agent 1.21/32.243 Xref: archiver1.google.com comp.lang.ada:19331 Date: 2002-01-28T16:23:33+00:00 List-Id: On Fri, 25 Jan 2002 00:09:44 +0000, Brian Rogoff wrote: >On Wed, 23 Jan 2002, Dmitry A. Kazakov wrote: >> On Tue, 22 Jan 2002 16:55:51 +0000, Brian Rogoff >> wrote: >> >> [...] >> >> >I prefer the generic approach to the OO approaches. >> > >> >IMHO OOP is not as important as the programming world has made it out to >> >be, and should be used a lot less than it is. >> >> If I substitute ADT for OO, will above remain correct then? > >I have no idea what point you are trying to make. OO approaches usually >provide some mix of inheritance (though Common List defstruct has >inheritance without OOP I think) and run time polymorphism/dynamic >dispatch. ADTs are an orthogonal feature/capability. In my view if you strip away myths from OO, the rest will be plain ADT, i.e. an ability to build new types from old ones. Inheritance and polymorphism are just methods [among many others] to ease that process. >To be specific, I much prefer a language like ML (even SML, which has no >objects) to one like Java. Of course, I'd rather have OCaml (or Ada) which >allows me to have OO features when they are appropriate. I just think that >OO features are not frequently needed or desirable. Let's forget objects and classes [it is enough to have types and variables] as well as implementation/compilation issues [for a minute (:-))]. Now, what is wrong with: 1. Any type* can be derived from 2. Any type* may have initialization and finalization 3. A dispatching argument can by of any type* [*] class-wide types are excluded. >You may certainly disagree, as there are still nations which allow that. Yes, becase IMO the rational part of OO is ADT and I believe that practically any program requires some form of ADT. Then I'd prefer ADT to generics. Regards, Dmitry Kazakov