From: ratsonjaniv@hotmail.com (Mr. J.)
Subject: passing an array to a generic function
Date: 21 Nov 2003 02:31:52 -0800
Date: 2003-11-21T02:31:52-08:00 [thread overview]
Message-ID: <fc116fae.0311210231.d4a9515@posting.google.com> (raw)
hi,
this is my generic function:
generic
type Index is (<>);
type Item is private;
type Arr is array(Index range <>) of Item;
with function "="(I1,I2 : Item) return Boolean is <>;
function Filter_Array(A: Arr) return Arr;
Now, I wanna write a create a Filter_String function according to it:
type Index is new Integer;
type Item is new Character;
type Arr is Array(1..23) of character;
function Filter_String is new Filter_Array(Index,Item,Arr,"=");
As U all experts guessed it won't compile, my question is how to pass
the array of character to my new function ?
10x,
J.
next reply other threads:[~2003-11-21 10:31 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-11-21 10:31 Mr. J. [this message]
2003-11-21 11:03 ` passing an array to a generic function Lutz Donnerhacke
2003-11-21 11:20 ` David C. Hoos
2003-11-21 11:35 ` Jean-Pierre Rosen
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox