comp.lang.ada
 help / color / mirror / Atom feed
From: Jean-Pierre Rosen <rosen@adalog.fr>
Subject: Re: Record type as generic parameter
Date: Thu, 13 Aug 2009 12:23:30 +0200
Date: 2009-08-13T12:23:30+02:00	[thread overview]
Message-ID: <ajp06h.ocv.ln@hunter.axlog.fr> (raw)
In-Reply-To: <2698b15a-7a94-45b5-90af-d0fb5929b1cf@w41g2000yqb.googlegroups.com>

Gautier write-only a �crit :
> [...] Then, my favourite Ada compiler
> doesn't want a record as generic parameter:
> 
>       generic
>         type Scenario is range <>;
>         type Association is record
>           scen: Scenario;
>           it  : Item;
>         end record;
>         scenario_definition: array(Positive range <>) of Association;
>       procedure Fill_Scenarios;
> 
> Any nice workaround ?

Any reason why you cannot make a generic package that would *export*
Association and Scenario_Definition (and procedure Fill_Scenarios),
rather than importing them?

-- 
---------------------------------------------------------
           J-P. Rosen (rosen@adalog.fr)
Visit Adalog's web site at http://www.adalog.fr



  reply	other threads:[~2009-08-13 10:23 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-13  9:52 Record type as generic parameter Gautier write-only
2009-08-13 10:23 ` Jean-Pierre Rosen [this message]
2009-08-13 13:34   ` Gautier write-only
2009-08-13 10:30 ` Jacob Sparre Andersen
replies disabled

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