[Info-vax] VMS Basic and quad by value

Arne Vajhøj arne at vajhoej.dk
Fri Sep 23 18:45:35 EDT 2022


On 9/23/2022 4:45 PM, Bill Gunshannon wrote:
> On 9/23/22 16:37, Arne Vajhøj wrote:
>> I am not good at Basic so I may be missing something obvious.
>>
>> As I read the manual then I should be able to pass a quad by value.
>>
>> But the compiler disagrees.
>>
>> Can anybody shed some light on this?
>>
> 
> Can you show us the code?

Sure.

$ type z1.bas
program z1

declare quad v

v = 123
call f(v)

end program
!

sub f(quad a by value)

     print a

end sub
$ bas z1

sub f(quad a by value)
...............^
%BASIC-E-NOTRECVBY, A may not be received BY VALUE
at line number 11 in file DISK2:[ARNE.ipc.redis]z1.bas;7
%BASIC-E-ENDNOOBJ, DISK2:[ARNE.ipc.redis]z1.bas;7 completed with 1 
diagnostic - object deleted

and the manual says:

<quote>
You can pass BYTE, WORD, LONG, QUAD, DOUBLE, GFLOAT, SINGLE,
SFLOAT, and TFLOAT values by value.
</quote>

This is on Alpha. There would be an obvious problem on VAX.

Arne






More information about the Info-vax mailing list