comp.lang.ada
 help / color / mirror / Atom feed
From: rcollinson@aol.com (RCollinson)
Subject: Calling generic children from their parent?
Date: 1999/06/23
Date: 1999-06-23T00:00:00+00:00	[thread overview]
Message-ID: <19990623004221.05877.00000987@ngol05.aol.com> (raw)

Problem:
I need to use a type in a generic parent body that is located in the generic
child specification.  I am having problems instantiating the child in the
parent's body.  The type is not recognized unless it is instantiated.  Any
ideas?

generic
type A;
type B;
package foo is
  type My_Type is tagged private;
  procedure Do_This;
  procedure Do_That;
...
  private
  type My_Type is
  record
...
  end record;
end foo;

with foo.bar;
package body foo is
  My_Var : Foo.Bar.My_Extended_Type;  -- !!! How do I get an instance of this
variable
                                                             -- !!! that is a
type from the generic child???
                                                             -- !!! Is this
possible???
end foo;
-- ********************************************************8
generic
package foo.bar is
   type My_Extended_Type is new My_Type with
   record
...
   end record;
...
end foo.bar;




             reply	other threads:[~1999-06-23  0:00 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-06-23  0:00 RCollinson [this message]
1999-06-23  0:00 ` Calling generic children from their parent? Dale Stanbrough
1999-06-23  0:00   ` rcollinson
1999-06-24  0:00     ` Tucker Taft
1999-06-24  0:00       ` rcollinson
1999-06-25  0:00         ` Tucker Taft
1999-07-01  0:00           ` rcollinson
1999-06-23  0:00 ` Matthew Heaney
replies disabled

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