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-Thread: 103376,45fb44c5bf432111 X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news1.google.com!npeer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!nntp.club.cc.cmu.edu!feeder.erje.net!feeder.news-service.com!nf02.dk.telia.net!starscream.dk.telia.net!news.tele.dk!news.tele.dk!small.news.tele.dk!bnewspeer01.bru.ops.eu.uu.net!bnewspeer00.bru.ops.eu.uu.net!emea.uu.net!newsfeed.arcor.de!newsspool1.arcor-online.net!news.arcor.de.POSTED!not-for-mail Date: Mon, 30 Aug 2010 15:28:42 +0200 From: Georg Bauhaus User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.2.8) Gecko/20100802 Thunderbird/3.1.2 MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: Global scope for instantiated generic package? References: <5vWdnTd5Lf6uM-bRnZ2dnUVZ_oidnZ2d@giganews.com> In-Reply-To: <5vWdnTd5Lf6uM-bRnZ2dnUVZ_oidnZ2d@giganews.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Message-ID: <4c7bb20b$0$6774$9b4e6d93@newsspool3.arcor-online.net> Organization: Arcor NNTP-Posting-Date: 30 Aug 2010 15:28:43 CEST NNTP-Posting-Host: 608992d7.newsspool3.arcor-online.net X-Trace: DXC=l12YO3S\Dhn]BlmkiiU@BiMcF=Q^Z^V3h4Fo<]lROoRa8kFjLh>_cHTX3jmV^MnF8o8UGi X-Complaints-To: usenet-abuse@arcor.de Xref: g2news1.google.com comp.lang.ada:13852 Date: 2010-08-30T15:28:43+02:00 List-Id: On 30.08.10 15:12, Trogdor wrote: > 2) Where, speciffically, do I place the above two lines (and the > associated "with" line) so that I can BigInt_io.get from the main > body and the package subprograms as well? One way to place the declarations is in a common package. with Ada.Text_IO; use Ada.Text_IO; package Big_Stuff is type BigInt is range 1..10_000_000_000_000; -- ... BigInt subprograms package BigInt_IO is new integer_IO(BigInt); end Big_Stuff; A main unit can then with package Big_Stuff (and "use" it); the procedure bodies in Big_Stuff's body will see BigInt_IO, too. Georg