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=unavailable autolearn_force=no version=3.4.4 Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail From: "Jeffrey R. Carter" Newsgroups: comp.lang.ada Subject: Re: Full view of a private partial view cannot be a subtype Date: Tue, 5 Dec 2017 19:16:15 +0100 Organization: Also freenews.netfront.net; news.tornevall.net; news.eternal-september.org Message-ID: References: <889a3aed-4e6b-49c8-8c1c-6f1478e8e077@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Date: Tue, 5 Dec 2017 18:16:15 -0000 (UTC) Injection-Info: reader02.eternal-september.org; posting-host="ddd03d8240ed4b3c78267063e548869a"; logging-data="22097"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+307ee6pM1XGqFMkG54OMf8WswCDHsxBY=" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 In-Reply-To: Content-Language: en-US Cancel-Lock: sha1:DnBzvw1TgVJR31P+GvljJAE9iDM= Xref: reader02.eternal-september.org comp.lang.ada:49379 Date: 2017-12-05T19:16:15+01:00 List-Id: On 12/05/2017 09:20 AM, Dmitry A. Kazakov wrote: > > If Button, Toggle_Button, Radio_Button etc were unrelated then in each event > handler within a monstrous case over all possible widgets emitting the event, > good luck finding their operations, cutting and pasting same code, you cannot > reuse because types are unrelated. Yes, generics they will serve the final > stroke to this insanity. If that were really the way you'd design such a thing if deprived of type extension then I would to think you were incompetent to design S/W. I wouldn't do it that way. > You are welcome to propose one. After all it is only the interface you have to > design. All the implementation can be based on an existing framework with > inheritance and overriding... The problem with trying to build such a layer on top of an existing framework is that they all use the C-inspired idea of giving up your thread of control to the framework and it making calls to code you provide. That's not how it should be done in a decent language. -- Jeff Carter "I did not rob a bank. If I'd robbed a bank, everything would be great. I tried to rob a bank, is what happened, and they got me." Take the Money and Run 139