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=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.224.169.1 with SMTP id w1mr16290551qay.4.1374771618054; Thu, 25 Jul 2013 10:00:18 -0700 (PDT) X-Received: by 10.50.4.38 with SMTP id h6mr281561igh.8.1374771618006; Thu, 25 Jul 2013 10:00:18 -0700 (PDT) Path: eternal-september.org!reader01.eternal-september.org!reader02.eternal-september.org!news.eternal-september.org!news.eternal-september.org!news.eternal-september.org!feeder.eternal-september.org!usenet.blueworldhosting.com!feeder02.blueworldhosting.com!news.glorb.com!cb17no236140qab.0!news-out.google.com!dk8ni1421qab.0!nntp.google.com!cb17no236137qab.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Thu, 25 Jul 2013 10:00:17 -0700 (PDT) In-Reply-To: <14e47bb4-a838-47f8-8617-eb404679d3af@googlegroups.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=66.126.103.122; posting-account=RxNzCgoAAACA5KmgtFQuaU-WaH7rjnAO NNTP-Posting-Host: 66.126.103.122 References: <14e47bb4-a838-47f8-8617-eb404679d3af@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <39c8fb6b-314c-4eae-80a5-74bfaf6de16b@googlegroups.com> Subject: Re: my instansiation of a generic Remote_Call_Interface need a type declared in a package of wrong categorization From: Adam Beneschan Injection-Date: Thu, 25 Jul 2013 17:00:18 +0000 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Xref: news.eternal-september.org comp.lang.ada:16514 Date: 2013-07-25T10:00:17-07:00 List-Id: On Thursday, July 25, 2013 9:26:13 AM UTC-7, donts...@gmail.com wrote: > Hi! >=20 >=20 >=20 > I have created the following test packages for my question: My_RCI and Te= st_RCI(generic). >=20 > I am trying to create a distributed application. I would like to make sev= eral of these packages generic. >=20 >=20 >=20 > In some cases I run into the issue, that I wish to instantiate a Remote_C= all_Interface package. >=20 > Below I have My_RCI. This package tries to instantiate the necessary pack= ages. However, the __body__ of Test_RCI need a type that is declared in Cor= e_Package. Core_Package is not of correct categorization (and I can't make = it become so). >=20 > The specification part of Test_RCI and My_RCI are not depending on Core_P= ackage. >=20 > As soon as I "with" the Core_Package I get error message of course. >=20 > Does it exists some method to "trinkle" Core_Package through to the body = of Test_RCI? I have tried quite a few things to solve this, and I have at t= he moment given up:) Can you move your generic instantiation to the body of My_RCI? It looks li= ke the only thing from the generic's specification that you need in the spe= cification of My_RCI is the procedure Test_RCI. You could declare that wit= hout a generic instantiation in My_RCI's spec, and in the body, make it a r= ename of This.Test_RCI. If the specification of Test_RCI is more complex, so that there's a number = of things that you want in the generic Test_RCI to be visible in My_RCI, th= en it might be possible to split the generic Test_RCI into two generic pack= ages so that you instantiate one in My_RCI's spec, and the problematic one = in My_RCI's body. =20 Note: I haven't tested any of this. -- Adam