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-Thread: 103376,2e2db8edf2656165 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!nx01.iad01.newshosting.com!newshosting.com!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed.icl.net!proxad.net!proxad.net!newsfeed.arcor.de!news.arcor.de!not-for-mail Date: Sat, 01 Oct 2005 17:19:40 +0200 From: Georg Bauhaus User-Agent: Debian Thunderbird 1.0.2 (X11/20050817) X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Constructing an object References: <1lw8oz33ao529.12ep5ay7rg4oc$.dlg@40tude.net> <5-GdnRjCgYZOfKneRVn-qw@megapath.net> <3dachnu33lly.fpr0wvf6nj05$.dlg@40tude.net> <88m4nn9wh78b$.1wtlfwjymgcom.dlg@40tude.net> In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Message-ID: <433ea8af$0$16493$9b4e6d93@newsread4.arcor-online.net> Organization: Arcor NNTP-Posting-Date: 01 Oct 2005 17:18:08 MEST NNTP-Posting-Host: e1be3eeb.newsread4.arcor-online.net X-Trace: DXC=O3>DI0HF5; Randy Brukardt wrote: > Actually, it wouldn't be that hard to add that to Ada 200Y. We have the > "overriding" keyword to specify overriding. Additional keywords could > specify other types of extension -- "extends" perhaps. That would look like: > > extends > procedure Finalize (Obj : in out My_Type); > > or perhaps > > extends after > procedure Finalize (Obj : in out My_Type); > > to specify when the parent routine is called. AFAICS, the programming language BETA, successor to Simula, has virtual patterns of the general kind, extending in descendants. (Everything in BETA is a pattern, "The abstraction mechanisms include class, procedure, function, coroutine, process, exception and many more, all unified into the ultimate abstraction mechanism: the pattern.") Virtual patterns actually use the wording suggested in this thread. http://www.daimi.au.dk/~beta/Manuals/latest/beta-intro/Introduction.html#H3_1 From http://www.daimi.au.dk/~beta/Manuals/latest/beta-intro/Virtual.html : "In fact a virtual pattern in BETA can only be extended and cannot be completely redefined." The word "inner" is used to denote a part of a superpattern that is defined in subpatterns. >From the second URL: A: (# V:< (# x: do I1; inner; I2 #) #); AA: A(# V::< (# y: do I3; inner; I4#) #) The pattern A has a virtual procedure attribute V. V has an attribute x and its do-part contains the execution of I1; inner; I2. The subpattern AA of A extends the definition of V. The extended definition of V in AA corresponds to the following object-descriptor (except for scope rules): 4.3 Combined descriptor (# x: ; y: do I1; I3; inner; I4; I2 #)