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.2 required=5.0 tests=BAYES_00,INVALID_MSGID, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,3085e94d514e346b X-Google-Attributes: gid103376,public From: Mats Weber Subject: Re: Generic procedures Date: 1997/11/13 Message-ID: <346B2BEF.D00FF2A2@elca-matrix.ch>#1/1 X-Deja-AN: 289902134 References: <34684A49.5BE8D37@masda.hv.se> Organization: ELCA Matrix SA Reply-To: Mats.Weber@elca-matrix.ch Newsgroups: comp.lang.ada Date: 1997-11-13T00:00:00+00:00 List-Id: Tobias Ritzau wrote: > I wonder if it is possible to have a generic procedure in a > package and do some instations in the same spec. It's not directly possible, because you can instantiate only after elaboration of the generic's body. The following little package shows you how you can work around the problem. package p is generic procedure gp; procedure p; -- is new gp; end p; package body p is procedure gp is begin null; end gp; procedure pi is new gp; procedure p renames pi; end p;