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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fac41,2c6139ce13be9980 X-Google-Attributes: gidfac41,public X-Google-Thread: 1014db,3d3f20d31be1c33a X-Google-Attributes: gid1014db,public X-Google-Thread: 103376,3d3f20d31be1c33a X-Google-Attributes: gid103376,public X-Google-Thread: f43e6,2c6139ce13be9980 X-Google-Attributes: gidf43e6,public X-Google-Thread: 1108a1,2c6139ce13be9980 X-Google-Attributes: gid1108a1,public X-Google-Thread: 109fba,2c6139ce13be9980 X-Google-Attributes: gid109fba,public From: mheaney@ni.net (Matthew Heaney) Subject: Re: Is ADA as good for graphics programming as C? (WAS: Re: Avoiding the second historic mistake) Date: 1997/07/15 Message-ID: #1/1 X-Deja-AN: 256952402 References: Organization: Estormza Software Newsgroups: comp.object,comp.software-eng,comp.lang.ada,comp.lang.eiffel,comp.lang.c,comp.lang.c++ Date: 1997-07-15T00:00:00+00:00 List-Id: In article , donh@syd.csa.com.au wrote: >Yes, through a round-about way using genericity. This is inelegant compared >with multiple inheritance. However, it's simple compared to the obscure >technique for acheiving multiple views in Ada95 Rationale, Section 4.6.3. >I'm still trying to comprehend that one! Be careful bandying about terms like "more elegant" and "less pure." Those are concepts invented by humans to convey an idea to another human. Nature doesn't care about what is more or less elegant, she only cares about what works and what doesn't. As system builders, especially as builders of software systems, we always have to be concerned with keeping things simple. The language designer must balance expressiveness of the language against inclusion of yet more features. Does the putative "elegance" of the MI solution outweigh the language complexity that would result had MI been included in Ada? Doesn't simplicity count for something? Should one reject Ada out of hand, because mixin inheritance in Ada using generics is "inelegant" compared to using multiple inheritence in Eiffel? Isn't it possible that there are other features of Ada, that allow some things to be done more easily or more elegantly than in Eiffel? Is the mechanism used to implement mixin inheritance so important that those other features aren't significant? The multiple view technique is an admittedly difficult idiom to understand - at first. But once apprehended, it makes perfect sense, and isn't hard to do. You get multiple views for free, because it builds on existing language mechanisms, and it very nearly gives you what you get in MI, without requiring that MI be part of the language. You may want to study my discussion of the Adapter pattern in the SIGAda patterns WG archives, where I specifically discuss and give code examples of the multiple views technique. Matt -------------------------------------------------------------------- Matthew Heaney Software Development Consultant (818) 985-1271