gm2
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gm2] VAR array parameter type compatibility


From: SiTex Graphics
Subject: Re: [Gm2] VAR array parameter type compatibility
Date: Wed, 3 Mar 2010 19:38:50 -0500

Hi Gaius,

Thanks for these fixes which have enabled more of our main application
to compile.

Any progress on either error displayed by the Cb.mod test I sent
privately?  The 'set element is too  low' error shows up in about 6
other modules, all much more complicated.  The assert failure also
shows up in a couple other modules.  I'm hoping that resolving these
issues might finally allow the full app to build.

Thanks,
Scott



On Fri, Feb 26, 2010 at 10:21 AM, Gaius Mulley <address@hidden> wrote:
> SiTex Graphics <address@hidden> writes:
>
>> Hi Gaius,
>>
>> I have a case where GM2 appears to enforce different type
>> compatibility rules depending on whether a VAR array parameter is a
>> variable or the parameter in a procedure.
>>
>> With
>>
>> TYPE
>>   fooADDRESS = ADDRESS;
>>
>> VAR
>>   foo : ARRAY [0..9] OF fooADDRESS;
>>
>> GM2 accepts a call to
>>
>> PROCEDURE DoAddress(VAR a : ARRAY OF ADDRESS)
>>
>> passing foo.  However, the following call produces a compiler error:
>>
>> PROCEDURE DoFoo(VAR f : ARRAY OF fooADDRESS);
>> BEGIN
>>   DoAddress(f);
>> END DoFoo;
>>
>> "'f' cannot be passed to a VAR formal parameter"
>>
>> Test code attached.  Compile with
>>
>> gm2 -fiso -c arraytype.mod
>>
>> -Scott
>
> Hi Scott,
>
> now fixed in the latest cvs - many thanks for the test code and bug
> report,
>
> regards,
> Gaius
>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]