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,FREEMAIL_FROM autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,f8a66fb9d0293bf4 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!newsfeed2.dallas1.level3.net!news.level3.com!newsfeed-00.mathworks.com!news.tele.dk!news.tele.dk!small.news.tele.dk!newsgate.cistron.nl!feeder1.cambrium.nl!feed.tweaknews.nl!news2.euro.net!newsfeed.freenet.de!newsfeed00.sul.t-online.de!newsmm00.sul.t-online.de!t-online.de!news.t-online.com!not-for-mail From: xadian Newsgroups: comp.lang.ada Subject: Re: Passing arrays to procedures Date: Wed, 22 Dec 2004 19:43:28 +0100 Organization: T-Online Message-ID: References: <41C98E38.7000908@mailinator.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Trace: news.t-online.com 1103740984 03 20862 oCXZr08LzgxbSzpn 041222 18:43:04 X-Complaints-To: usenet-abuse@t-online.de X-ID: Z2TSqsZOge1hE0mxGMF3KGJXTV9xTsKz0sO3EtKqqv61cL+OtITFcq User-Agent: Mozilla Thunderbird 0.7 (Windows/20040616) X-Accept-Language: en-us, en In-Reply-To: <41C98E38.7000908@mailinator.com> Xref: g2news1.google.com comp.lang.ada:7179 Date: 2004-12-22T19:43:28+01:00 List-Id: Alex R. Mosteo wrote: > > > You must declare an array type and use it in the function declaration: > > type Blah is array (Integer range <>) of Something; > > procedure Procname (N : in Integer; v1 : in Blah) is... > > of course you can declare the array type where it best fit your design. Well actually I have no idea where to declare that type... I've got two files. One with that procedure and one with the main procedure. In the main procedure I call that other one. The declaration can't be in the main procedure because it wont be known in the procedure (thats what the compiler sais) and it can't be declared in the seperate procedure-file, because there is no way to declare sth before the procedure starts. I already tried to declare both proedures in one file but then it sais sth like "end of file expected" after the "end;" of the first of these two procedures... So where now can I declare that type?! xadian PS The array i want to pass has a variable size, so there is no way to use a contraint one (if that is important).