From: Sami Evangelista <sami.evangelista@wanadoo.fr>
Subject: Re: generic packages
Date: Tue, 09 Jul 2002 15:41:45 +0200
Date: 2002-07-09T13:40:08+00:00 [thread overview]
Message-ID: <3D2AE819.90000@wanadoo.fr> (raw)
In-Reply-To: 3D2AE4E9.3020208@laas.fr
Fabien Garcia wrote:
> Sami Evangelista wrote:
> > [snip]
>
>> is there any solution ?
>>
>> thanks for any help
>
> I would try something like this :
>
>
> -----------------------------------------------------------------
> generic
> type Element_a is private;
> type element_b is private;
> with function eq_a (E1, E2 : in Element_a) return boolean;
> with function eq_b (E1, E2 : in Element_b) return boolean;
> with function a_to_b(A : in Element_a) return element_b;
> package A_Set_To_B_set_pack is
>
> package a_set is new generic_set (Element_a,eq_a);
> package b_set is new generic_set (Element_b,eq_b);
>
> function a_set_to_b_set(the_set : in a_set.set) return b_set.set;
> ------------------------------------------------------------------
> Fabien Garcia
>
>
>
thank you for your response.
but is it possible to declare it in the generic_set.ads file?
i have tried to put a_set_to_b_set into another file but then i can't
access to the private type of the generic_set package like el or others_els.
next prev parent reply other threads:[~2002-07-09 13:41 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-07-09 13:03 generic packages Sami Evangelista
2002-07-09 13:28 ` Fabien Garcia
2002-07-09 13:41 ` Sami Evangelista [this message]
2002-07-10 2:00 ` SteveD
2002-07-11 13:41 ` Sami Evangelista
2002-07-11 20:56 ` Adam Beneschan
-- strict thread matches above, loose matches on Subject: below --
2001-04-19 21:27 Generic Packages Eyal Ben-gal
2001-04-19 20:26 ` Ehud Lamm
2001-04-19 22:09 ` Robert A Duff
2001-04-20 6:50 ` Ehud Lamm
2000-02-16 0:00 Generic packages David Olsson
2000-02-16 0:00 ` R. Tim Coslet
1998-08-10 0:00 Generic Packages Tory Patnoe
1998-08-11 0:00 ` Tucker Taft
1998-08-11 0:00 ` Robert I. Eachus
1998-08-12 0:00 ` Dale Stanbrough
1998-08-17 0:00 ` Dr. Hubert B. Keller
1998-08-27 0:00 ` Simon Wright
[not found] <5e03nm$esq@netty.york.ac.uk>
1997-02-15 0:00 ` Jon S Anthony
1997-02-20 0:00 ` phtruong
1997-02-21 0:00 ` Robert Dewar
1997-02-25 0:00 ` Quorlia
1997-02-27 0:00 ` Robert Dewar
[not found] <4inq3c$lr9@NNTP.MsState.Edu>
1996-03-22 0:00 ` John Herro
1996-03-22 0:00 ` Samuel Tardieu
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox