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,8c424d8135e68278 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2001-12-17 09:52:30 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!newsfeed.direct.ca!look.ca!newsfeed.bc.tac.net!news.bc.tac.net!not-for-mail Sender: blaak@TORUS Newsgroups: comp.lang.ada Subject: Re: Ada2005 References: <9v4jsj$bd1$1@infosun2.rus.uni-stuttgart.de> <9v7f26$qn2$1@infosun2.rus.uni-stuttgart.de> <3C1754BA.C4560423@informatik.uni-jena.de> <3c1868b2.1587625@News.CIS.DFN.DE> From: Ray Blaak Message-ID: Organization: The Transcend X-Newsreader: Gnus v5.7/Emacs 20.7 Date: 17 Dec 2001 09:50:30 -0800 NNTP-Posting-Host: 208.181.209.61 X-Complaints-To: news@bctel.net X-Trace: news.bc.tac.net 1008611544 208.181.209.61 (Mon, 17 Dec 2001 09:52:24 PST) NNTP-Posting-Date: Mon, 17 Dec 2001 09:52:24 PST Xref: archiver1.google.com comp.lang.ada:18018 Date: 2001-12-17T09:50:30-08:00 List-Id: dmitry@elros.cbb-automation.de (Dmitry A. Kazakov) writes: > However, what people criticizing Ada usualy want, is just a syntax > sugar, which would allow to refer methods using postfix form if there > is only one dispatching [or class-wide] argument and it is the first > one. Like me. > I think in a future revision there could be some variant of rename > statement which would allow to do this and also the opposite thing > [for "methods" of protected objects and tasks which are always called > using the postfix form]. For instance: > > type Ellipse is tagged ... > procedure Draw (Figure : Ellipse, Where : Point); > entry Ellipse.Draw (Where : Point) renames Draw; Why not make it automatic? The extra declaration is tedious and requires extra maintenance. Given: e : Ellipse; then have e.Draw(p) be valid iff Draw exists with an Ellipse as its first parameter. Then it is truly just an alternate syntax to be used if desired, and not used if not. Where it gets wierd, I suppose, is if one has an "in out" or "out" parameter. One wants to allow update methods, but does e.Draw(p) make sense if e is completely replaced? -- Cheers, The Rhythm is around me, The Rhythm has control. Ray Blaak The Rhythm is inside me, blaak@telus.net The Rhythm has my soul.