guile-user
[Top][All Lists]
Advanced

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

Re: Pass by reference. un-schemey?


From: John E. Kreznar
Subject: Re: Pass by reference. un-schemey?
Date: 23 Dec 2001 16:18:11 -0800

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Sam Phillips <address@hidden> writes:

> Is there an easy way to pass a variable by reference into a procedure?

Put it inside a lambda, such as a thunk.  Instead of calling (sub x),
use (sub (lambda () x)).  Inside of sub, where you would otherwise
refer to just x, refer instead to (x).

- -- 
 John E. Kreznar address@hidden 9F1148454619A5F08550 705961A47CC541AFEF13
                    No truckle to any body politic
  Imagine there's no countries / to kill or die for  --John Lennon, 1971
     Disavowal of political allegiance is prerequisite to freedom.
 
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: Processed by Mailcrypt 3.5.6 and Gnu Privacy Guard 
<http://www.gnupg.org/>

iD8DBQE8JnQeYaR8xUGv7xMRAvKrAJ0RK8oRpW7s7OXyC1pmX/043N9r/QCfe/cv
ZBiM6JG0c7bEutHpOSzq/zQ=
=/0S7
-----END PGP SIGNATURE-----



reply via email to

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