On Sun, 11 Nov 2007 20:52:10 -0600, david.williams@[EMAIL PROTECTED]
(David
Williams) wrote:
<snip>
>Of course, it is easy to make BASIC pass parameters by value by writing
>them as arithmetic expressions, rather than single variables:
>
>CALL Routine (X + 0)
>
>Even if Routine changes the value of its input parameter, the value of
>X in the calling routine is unaltered. I don't think I have ever done
>this in practice, but I can see that it might sometimes be useful.
But, that method generates a bunch of extra code. :-) And, it is
still a pass by reference, just of a temp var, instead of X.
--
ArarghMail711 at [drop the 'http://www.'
from ->] http://www.arargh.com
BCET Basic Compiler Page: http://www.arargh.com/basic/index.html
To reply by email, remove the extra stuff from the reply address.


|