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,fba93c19bb4e7dbd X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-07-21 01:34:33 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!bloom-beacon.mit.edu!nycmny1-snh1.gtei.net!news.gtei.net!newsfeed.mathworks.com!fu-berlin.de!uni-berlin.de!tar-alcarin.cbb-automation.DE!not-for-mail From: Dmitry A. Kazakov Newsgroups: comp.lang.ada Subject: Re: Q: Endless loop by dispatching Date: Mon, 21 Jul 2003 10:38:35 +0200 Message-ID: <818nhv0hrmlheu622t82574blao7bqr0tt@4ax.com> References: <3F188FDA.3000202@attbi.com> <3F18DB9D.5020205@attbi.com> NNTP-Posting-Host: tar-alcarin.cbb-automation.de (212.79.194.111) Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: news.uni-berlin.de 1058776471 14878013 212.79.194.111 (16 [77047]) X-Newsreader: Forte Agent 1.8/32.548 Xref: archiver1.google.com comp.lang.ada:40535 Date: 2003-07-21T10:38:35+02:00 List-Id: On Sat, 19 Jul 2003 05:48:23 GMT, "Robert I. Eachus" wrote: >1) All objects of a type derived from Ada.Finalization.Controlled by >default call the same version of Initialize? Which one version? How a public part might know that there is a privately declared Initialize? >or > >2) Information hiding in effect AT THE PLACE OF THE CALL can determine >which version of a subprogram is called? For good or bad, but this was the intention, i.e. to hide Initialize and here you are. >If you vote for 2), I won't argue, I'll take it as data. The important >part for the ARG is that in this (foot shooting) case we have to choose. > The two alternatives are clearly incompatible, and that is what the >program was written to demostrate. IMO the problem is that you can have both an overloading in the public part and an overriding in the private. This is a nasty problem, because: 1<-->A. if we prohibit this, we would expose something from the private part; 2<-->B. if we accept this, we have pitfalls as your example shows. I think that the syntax should clearly distinguish declaring a primitive (and thus overriding) vs. non-primitive (overloading) subprogram. Further, no matter how painful it could be, one should probably outlaw non-primitive subprograms with tagged non-class-wide arguments. This again would solve little as long as a type can be publicly non-tagged, being tagged privately. So again I have to repeat the same old slogan: ALL TYPES BE TAGGED! --- Regards, Dmitry Kazakov www.dmitry-kazakov.de