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.107.162.142 with SMTP id l136mr15741376ioe.16.1512487637140; Tue, 05 Dec 2017 07:27:17 -0800 (PST) X-Received: by 10.157.81.193 with SMTP id d1mr836081oth.13.1512487637022; Tue, 05 Dec 2017 07:27:17 -0800 (PST) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!feeder.eternal-september.org!news.kjsl.com!usenet.stanford.edu!193no1880854itr.0!news-out.google.com!s63ni4809itb.0!nntp.google.com!193no1880853itr.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Tue, 5 Dec 2017 07:27:16 -0800 (PST) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=155.148.6.150; posting-account=lJ3JNwoAAAAQfH3VV9vttJLkThaxtTfC NNTP-Posting-Host: 155.148.6.150 References: <889a3aed-4e6b-49c8-8c1c-6f1478e8e077@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <43498b2a-773c-454a-b0e7-ade5d6594bd4@googlegroups.com> Subject: Re: Full view of a private partial view cannot be a subtype From: Shark8 Injection-Date: Tue, 05 Dec 2017 15:27:17 +0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Xref: reader02.eternal-september.org comp.lang.ada:49378 Date: 2017-12-05T07:27:16-08:00 List-Id: On Monday, December 4, 2017 at 2:48:34 PM UTC-7, Jeffrey R. Carter wrote: > On 12/04/2017 09:41 PM, Jere wrote: > >> > > I don't disagree in general per say, but that is a very subjective thin= g. I > > don't find composition nearly as readable as you do. It has it's place= and > > can be more readable, but (maybe it's just how I read and visualize) I = find > > extension to be more readable in probably more cases than you typically= do. > > It's just a personal thing with how I read. I've used and written both= . >=20 > I've never seen a realistic problem that was as readable when implemented= with=20 > type extension as with composition. >=20 > Perhaps the best fit of any problem with type extension is a GUI framewor= k,=20 > since everything "is-a" widget. I have used 2 such frameworks implemented= using=20 > type extension, Claw and Gnoga, and both are very difficult to understand= . The=20 > derivation trees are very deep and there are a huge number of inherited= =20 > operations. It's effectively impossible to know all the operations for th= e most=20 > commonly used types, which tend to be down at the leaves of the derivatio= n tree.=20 One of the best GUI frameworks I've seen is Delphi's VCL -- it is very good= in this respect having several "base level" types where you'll look for co= mmon operations. (There's one for visual-components, one for nonvisual-comp= onents, and they both share an ancestor that is [IIRC] higher than TObject.= ) Besides UIs, the one problem that springs immediately to mind is the intern= als of a compiler's IR/parse-tree. Another is linguistics (though I haven't= actually seen this used) where you are modelling language on a abstract/ge= neral level: Types Verb & Noun, descending from Word. Phrases, sentences, e= tc.