[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: mutating C binding arguments?
From: |
Michael Livshin |
Subject: |
Re: mutating C binding arguments? |
Date: |
03 Oct 2000 20:06:04 +0200 |
User-agent: |
Gnus/5.0807 (Gnus v5.8.7) XEmacs/21.1 (20 Minutes to Nikko) |
"Lars J. Aas" <address@hidden> writes:
> How do I mutate an argument to a gsubr-bound function so I can
> emulate C++ pass-by-reference in a Guile binding? Is it even
> possible for immediate types?
no. the proper Scheme way to have multiple results from a function
is to use call-with-values & values.
they are not reflected in the C interface now. perhaps they should
be.
or you can just box your "mutable" arguments, i.e. wrap them in a
cons. come to think of it, I recall that MzScheme has a special `box'
datatype for such occasions. perhaps we should have one too, if
there's demand.
--
One man's constant is another man's variable.
-- Alan Perlis
- mutating C binding arguments?, Lars J. Aas, 2000/10/03
- Re: mutating C binding arguments?,
Michael Livshin <=
- Re: mutating C binding arguments?, Lars J. Aas, 2000/10/04
- Re: mutating C binding arguments?, Michael Livshin, 2000/10/04
- Re: mutating C binding arguments?, Lars J. Aas, 2000/10/04
- Re: mutating C binding arguments?, Michael Livshin, 2000/10/04
- Re: mutating C binding arguments?, Lars J. Aas, 2000/10/04
- Re: mutating C binding arguments?, Michael Livshin, 2000/10/04
- Re: mutating C binding arguments?, Michael Livshin, 2000/10/04
- Re: mutating C binding arguments?, Lars J. Aas, 2000/10/04
- Re: mutating C binding arguments?, Michael Livshin, 2000/10/04
- Re: mutating C binding arguments?, Lars J. Aas, 2000/10/05