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,b18ccf7d301fe37 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-04-19 09:34:53 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!hammer.uoregon.edu!skates!not-for-mail From: Stephen Leake Newsgroups: comp.lang.ada Subject: Re: Invoking abstract subprograms in Ada95 Date: 19 Apr 2002 12:18:53 -0400 Organization: NASA Goddard Space Flight Center (skates.gsfc.nasa.gov) Message-ID: References: <2dbd76f3.0204190515.10e6aef0@posting.google.com> NNTP-Posting-Host: anarres.gsfc.nasa.gov Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: skates.gsfc.nasa.gov 1019233507 16150 128.183.220.71 (19 Apr 2002 16:25:07 GMT) X-Complaints-To: usenet@news.gsfc.nasa.gov NNTP-Posting-Date: 19 Apr 2002 16:25:07 GMT User-Agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.2 Xref: archiver1.google.com comp.lang.ada:22787 Date: 2002-04-19T16:25:07+00:00 List-Id: michael.jackson5@virgin.net (Mike) writes: > In Ada 95 terms I have a package X that contains abstract type Xt and > describes some abstract behaviour "procedure Z". I also have Ada95 > Child Package X.Y that contains a non abstract type Yt that extends > and fully completes Xt. > > Within package X I have a classwide procedure (actually an XWindows > Callback) that I want to be invoked by all types of child, *but* there > are some specific tasks that can only be completed by the concrete > child (Y in this case) that fully implements procedure Z. > > Gnat Ada95 will not let me do this: "Cannot call abstract subprogram" > > * Why can I not invoke procedure Z from with package X? Apparently you have coded a non-dispatching call. Please post the code. -- -- Stephe