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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,72113392dc4997bd X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-04-16 19:54:03 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!arclight.uoregon.edu!wn13feed!wn12feed!worldnet.att.net!bgtnsc04-news.ops.worldnet.att.net.POSTED!not-for-mail Reply-To: "James S. Rogers" From: "James S. Rogers" Newsgroups: comp.lang.ada References: <1ftiuys.1twhum2q9qa00N%claveman@grzorgenplatz.net> Subject: Re: Subprogram Pointer in a Generic X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1106 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1106 Message-ID: Date: Thu, 17 Apr 2003 02:54:02 GMT NNTP-Posting-Host: 12.86.35.73 X-Complaints-To: abuse@worldnet.att.net X-Trace: bgtnsc04-news.ops.worldnet.att.net 1050548042 12.86.35.73 (Thu, 17 Apr 2003 02:54:02 GMT) NNTP-Posting-Date: Thu, 17 Apr 2003 02:54:02 GMT Organization: AT&T Worldnet Xref: archiver1.google.com comp.lang.ada:36224 Date: 2003-04-17T02:54:02+00:00 List-Id: "Charles H. Sampson" wrote in message news:1ftiuys.1twhum2q9qa00N%claveman@grzorgenplatz.net... > I'm using a procedure that takes a procedure pointer as an > argument. It's pretty standard stuff: > > type Parameterless_Proc_Ptr is access procedure; > procedure Register (The_Proc : in Parameterless_Proc_Ptr); > > My problem occurs when I want to call this procedure from within a > generic package. I can't, because 3.10.2(32) says "If the subprogram > denoted by P [the prefix of 'Access] is declared within a generic body, > S [the access-to-subprogram type of the formal parameter] shall be > declared within the generic body." Why are you passing a procedure access to a generic? Why not simply pass the procedure as a simple generic parameter: generic with procedure Parameterless_Proc; This will allow you to call the actual procedure without any of the issues you describe. Jim Rogers