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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,88e7ef9008757431 X-Google-Attributes: gid103376,public From: Francois Godme Subject: Re: Function Calls by Address Date: 1999/09/06 Message-ID: <37D41767.CEB186F4@magic.fr>#1/1 X-Deja-AN: 521804534 Content-Transfer-Encoding: 7bit References: <37CADE68.6AF06F5D@escmail.orl.lmco.com> <37CEEFFA.7D73F78D@magic.fr> <7qooh7$hbh$1@nnrp1.deja.com> <37CFFEA6.921CBE59@magic.fr> <7qp5oo$2un@hobbes.crc.com> <7qptoa$cul$1@nnrp1.deja.com> <37D2E1A7.CAC3F923@magic.fr> <7qvasf$sno$1@nnrp1.deja.com> X-Client: Magic On Line [unknown@ppp-101.net2.magic.fr] X-Accept-Language: fr Content-Type: text/plain; charset=us-ascii Organization: very little Mime-Version: 1.0 Newsgroups: comp.lang.ada Date: 1999-09-06T00:00:00+00:00 List-Id: Robert Dewar wrote: > In article <37D2E1A7.CAC3F923@magic.fr>, > Francois Godme wrote: > > Yes, back in the Ada83 days, this was a good use (you were > almost > > forced) but now, you can do it in better ways. One way would > be to > > define an abstract tagged type that abstracts what you want to > do and to > > implement several concrete subclasses of this abstraction, one > for each > > target. Only the main subprogram will know on which target it > is running > > and will pass down to the application the appropriate instance > or the > > appropriate factory to build instances. > > I am certain you did NOT follow the advice of the message to > which you are replying, and have a look at ??emstop.adb in > the GNAT sources. The above comments are really not relevant > to the use illustrated there. > > Sent via Deja.com http://www.deja.com/ > Share what you know. Learn what you don't. Robert, please can you be less enigmatic. I do not see why it is not relevant. Is it wrong to think that Machine_State_Operations gathered methods that apply on a Machine_State, as its own name may imply? Is it wrong to think that an abstract tagged type could fill the same purpose, if it was allowed in this context? By the way, it seems to me that your example only stands as a justification for the use of the separate construct in a language subset we don't write programs with, the subset of the Ada language allowed to write the GNAT runtime.