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.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,f45af6dd43d3673a X-Google-Attributes: gid103376,public From: v025@truman.edu (Chad R. Meiners) Subject: Re: Controlled type question Date: 1999/02/15 Message-ID: <36c765d4.0@silver.truman.edu>#1/1 X-Deja-AN: 444487984 References: <36c743da.0@silver.truman.edu> Content-Type: Text/Plain; charset=US-ASCII Organization: Missouri Research and Education Network Mime-Version: 1.0 Newsgroups: comp.lang.ada Date: 1999-02-15T00:00:00+00:00 List-Id: In article , matthew_heaney@acm.org says... > > >Yes, you hit upon a rule, the one that says > > Controlled type must be declared at the library level > >You have this: > > package GP is > ... > private > type T is new ...; > end GP; > > >That's fine, but the illegal thing is doing this: > >package Q is >... > package P is new GP (...); > >end Q; > >The problem is that inside the scope of package Q, you're not at library >level, and so the instantiation of GP is illegal. > >You can try fixing it like this: > >package Q is >... >end Q; > >private package Q.P is new GP (...); > > >(I think that's it. Let me know if I interpreted things incorrectly.) Thank you. I wrote a four line ads file to do this and it works great. -Chad R. Meiners