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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,760a0492b97ae06e X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-12-20 10:20:24 PST Path: archiver1.google.com!news2.google.com!newsfeed2.dallas1.level3.net!news.level3.com!crtntx1-snh1.gtei.net!news.gtei.net!newsfeed1.easynews.com!easynews.com!easynews!small1.nntp.aus1.giganews.com!border3.nntp.aus1.giganews.com!intern1.nntp.aus1.giganews.com!nntp.giganews.com!nntp.comcast.com!news.comcast.com.POSTED!not-for-mail NNTP-Posting-Date: Sat, 20 Dec 2003 12:20:22 -0600 Date: Sat, 20 Dec 2003 13:20:20 -0500 From: "Robert I. Eachus" User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax) X-Accept-Language: en-us, en MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: How to test object hierarchy References: <93172edb.0312181024.9a536b2@posting.google.com> <1071844528.57052@master.nyc.kbcfp.com> In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Message-ID: <06idnS2-ndV7D3miRVn-hQ@comcast.com> NNTP-Posting-Host: 24.34.214.193 X-Trace: sv3-tBqyU/JZFp1rABXtJ7yYqfILSLA9rnpznw3f/0XLGk8bw5DsaUfjXXDgNrAcUebLMQZdfii1EvnuGiG!Cpj9Ho0PzaxanPF4an/EnkR/f7QsAqSMb8aoachgBJzkSQuTW3iuMAmq/qmExA== X-Complaints-To: abuse@comcast.net X-DMCA-Complaints-To: dmca@comcast.net X-Abuse-and-DMCA-Info: Please be sure to forward a copy of ALL headers X-Abuse-and-DMCA-Info: Otherwise we will be unable to process your complaint properly X-Postfilter: 1.1 Xref: archiver1.google.com comp.lang.ada:3634 Date: 2003-12-20T13:20:20-05:00 List-Id: Robert A Duff wrote: > Yes, it can be instance. It can also be a renaming. ... > I didn't follow the entire discussion, but yes, I think that could work. Before somebody gets bent all out of shape trying to implement the idea, there is a subtle gotcha here that has to be avoided. It is often difficult (but not impossible) to define the generic you want before the freezing point. There are two workarounds, which often occur naturally. The first is to make the signature of the subprogram dispatching. Then in the body, implement the subprogram as a generic instance. Or you can make the generic an operation of a parent type, so that the generic instantiation can appear before the freezing point of the child type, but after the freezing point of the parent. As I said, you may naturally not run into a problem. Depends on how you define the generic and other things. But if you do have a problem, move the instantiation to the body of the package that defines the type. -- Robert I. Eachus "The war on terror is a different kind of war, waged capture by capture, cell by cell, and victory by victory. Our security is assured by our perseverance and by our sure belief in the success of liberty." -- George W. Bush