From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,3849a7e484f56749 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2002-07-09 06:30:04 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!logbridge.uoregon.edu!kibo.news.demon.net!demon!diablo.netcom.net.uk!netcom.net.uk!fr.clara.net!heighliner.fr.clara.net!lirmm.fr!ciril.fr!univ-lille1.fr!news.cict.fr!news.laas.fr!not-for-mail From: Fabien Garcia Newsgroups: comp.lang.ada Subject: Re: generic packages Date: Tue, 09 Jul 2002 15:28:09 +0200 Organization: LAAS-CNRS, Toulouse, France Message-ID: <3D2AE4E9.3020208@laas.fr> References: <3D2ADF27.8070502@wanadoo.fr> NNTP-Posting-Host: pppport13.laas.fr Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Trace: kane.laas.fr 1026221220 11730 140.93.18.114 (9 Jul 2002 13:27:00 GMT) X-Complaints-To: abuse@laas.fr NNTP-Posting-Date: 9 Jul 2002 13:27:00 GMT User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; fr-FR; rv:0.9.4.1) Gecko/20020508 Netscape6/6.2.3 X-Accept-Language: fr-fr Xref: archiver1.google.com comp.lang.ada:26966 Date: 2002-07-09T13:27:00+00:00 List-Id: 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