comp.lang.ada
 help / color / mirror / Atom feed
From: Adam Beneschan <adam@irvine.com>
Subject: Re: Signature Package With Generic Proceedure
Date: Sat, 21 Jul 2012 15:22:36 -0700 (PDT)
Date: 2012-07-21T15:22:36-07:00	[thread overview]
Message-ID: <a1816272-ef92-4402-bc3a-991bd8522697@googlegroups.com> (raw)
In-Reply-To: <045f7b44-2a4a-4292-80fd-0b6bc8ee3465@googlegroups.com>

On Saturday, July 21, 2012 10:22:25 AM UTC-7, Keean Schupke wrote:
> If I have a package which defines a procedure like:
> 
> 
> generic
>     with procedure Process(Set : in out Set_Type);
> procedure Update(Set : in out Set_Type);
> 
> 
> How do a declare a Signature package that includes this?
> 
> 
> generic
>     with generic
>         with procedure Process(Set : in out Set_Type);
>     procedure Update(Set : in out Set_Type);
> package Set_Signature is end;
> 
> 
> Is not allowed. Is there some way to do this with nested packages?

There's no such thing as "with generic" in Ada.  That is, there is no way to set things up so that you can instantiate a generic like this:

   package An_Instantiation is new A_Generic (G1);

where G1 is the name of a *generic* subprogram or package.  Nor can I think of a reason why you'd want to.  Perhaps if you gave us an example of what you're trying to accomplish?

                              -- Adam



       reply	other threads:[~2012-07-26 14:45 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <045f7b44-2a4a-4292-80fd-0b6bc8ee3465@googlegroups.com>
2012-07-21 22:22 ` Adam Beneschan [this message]
2012-07-22  7:28   ` Signature Package With Generic Proceedure Dmitry A. Kazakov
2012-07-22 16:22   ` Keean Schupke
2012-07-23  0:45     ` Adam Beneschan
     [not found]       ` <79925d0c-b2dd-44a3-9451-48f0ee19485f@googlegroups.com>
     [not found]         ` <500d3a9d$0$6566$9b4e6d93@newsspool4.arcor-online.net>
2012-07-23 18:29           ` Keean Schupke
     [not found]         ` <ac8bfaed-dbcc-491a-a760-c25672445eef@googlegroups.com>
2012-07-23 19:41           ` Keean Schupke
2012-07-24  2:57         ` Randy Brukardt
     [not found]         ` <jul2n4$af5$1@munin.nbi.dk>
2012-07-24  8:02           ` Keean Schupke
2012-07-24  8:43             ` Dmitry A. Kazakov
2012-07-24  8:59               ` Keean Schupke
2012-07-23 10:26 ` Simon Wright
2012-07-23 18:36   ` Keean Schupke
replies disabled

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