comp.lang.ada
 help / color / mirror / Atom feed
From: lance@lainet.com (Lance )
Subject: Help! type extensions - Gnat for Win95
Date: 1996/04/14
Date: 1996-04-14T00:00:00+00:00	[thread overview]
Message-ID: <317169a3.48223533@news.lainet.com> (raw)

I am trying to make a hierarchy of data structures as a hierarchy of
types.   Consider the following code:

---------------------------------------------------------------------------
package Containers is
  type Container is abstract tagged private;
private
  type Container is abstract tagged null record;
end Containers;

package Containers.Stacks is
  type Stack is new Container with private;
  procedure Put (S: Stack) is abstract;
private
  type Stack is new Container with null record;
end Containers.Stacks;

package Containers.Stacks.Bounded_Stacks is
  type Bounded_Stack is limited private;
private
  type Bounded_STack is new *Stack with record
      ---------
      ---------
  end record;
end Containers.Stacks.Bounded_Stacks;
------------------------------------------------------------------------------------

All of the above code compiles fine.  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)
  

Thanks in advance for any help that you may be able to provide.

Lance
lance@lainet.com




             reply	other threads:[~1996-04-14  0:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1996-04-14  0:00 Lance  [this message]
1996-04-14  0:00 ` Help! type extensions - Gnat for Win95 Robert A Duff
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox