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,6129ccd596d4814d X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news4.google.com!newshub.sdsu.edu!elnk-nf2-pas!newsfeed.earthlink.net!stamper.news.pas.earthlink.net!stamper.news.atl.earthlink.net!newsread2.news.atl.earthlink.net.POSTED!d9c68f36!not-for-mail From: Marin David Condic User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.7.2) Gecko/20040804 Netscape/7.2 (ax) X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Abstract Operations On A Tagged Record References: <2uhsidF2ahq9fU1@uni-berlin.de> <3qqhd.16031$ta5.3884@newsread3.news.atl.earthlink.net> <2uncfjF2c34toU1@uni-berlin.de> In-Reply-To: <2uncfjF2c34toU1@uni-berlin.de> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Message-ID: Date: Sat, 06 Nov 2004 13:17:36 GMT NNTP-Posting-Host: 209.165.4.234 X-Complaints-To: abuse@earthlink.net X-Trace: newsread2.news.atl.earthlink.net 1099747056 209.165.4.234 (Sat, 06 Nov 2004 05:17:36 PST) NNTP-Posting-Date: Sat, 06 Nov 2004 05:17:36 PST Organization: EarthLink Inc. -- http://www.EarthLink.net Xref: g2news1.google.com comp.lang.ada:6020 Date: 2004-11-06T13:17:36+00:00 List-Id: BTW: I've been mucking around with this for the last few days and, after much struggling, have concluded that attempting to do this (while it may indeed work) started becoming entirely too unwieldy. Trying to keep stalling off the problems with more and more layers of indirection started becoming painful. What I'm doing is basically leaving those operations out of the base class and (where it makes sense) I'm creating layer(s) of intermediate classes that get more and more specific about what the required parameter types are. Its still rather "heavy" (you have to keep isolating things in more packages and creating more branches in the class tree) but it seemed less painful than trying to find all the necessary abstractions & provide all the needed operations on the parameter class. Sometimes you just have to bite the bullet and say "here's a version that deals with a float and here's a version that deals with a boolean and its just not worth the pain of trying to make them both be the same thing..." But at least I got a better understanding of what I'm dealing with, eh? MDC Nick Roberts wrote: > > I'm fairly certain that you require something like: > > procedure Some_Op (The_Thing : in out Some_Tagged_Type; > The_Params: in Some_Parameter_Type'Class) > is abstract ; > -- ====================================================================== Marin David Condic I work for: http://www.belcan.com/ My project is: http://www.jsf.mil/NSFrames.htm Send Replies To: m o d c @ a m o g c n i c . r "Power corrupts. Absolute power is kind of neat" -- John Lehman, Secretary of the Navy 1981-1987 ======================================================================