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,49a391566586ce57 X-Google-Attributes: gid103376,public From: bobduff@world.std.com (Robert A Duff) Subject: Re: Help! type extensions - Gnat for Win95 Date: 1996/04/14 Message-ID: #1/1 X-Deja-AN: 147498512 references: <317169a3.48223533@news.lainet.com> organization: The World Public Access UNIX, Brookline, MA newsgroups: comp.lang.ada Date: 1996-04-14T00:00:00+00:00 List-Id: In article <317169a3.48223533@news.lainet.com>, Lance wrote: >All of the above code compiles fine. It shouldn't. You need to make Stack abstract, since it has an abstract primitive operation. >... However, I try to use the >package in test program the compiler tells me "type extension at >deeper accessibility level than parent." at the line in >Containers.Stacks.Bounded_STacks that defines the type. (marked with * >above) Don't extend these types in procedures or functions. If the thing is generic, don't instantiate it in a procedure or function. Instantiate it at library level (i.e. as a library unit, or nested within a package, but not within a procedure). - Bob