"R. Kent Dybvig" <dyb_at_cs.indiana.edu> writes:
>> So, maybe it's just me, but you see I'm having trouble understanding
>> the subtleties of the Chez model for parameters.
>
> I think it would have been easier for you had you accepted my original
> statement that Chez Scheme's model has the semantics you seem to want as
> long as mutation isn't involved. You could have answered most if not all
> of your subsequent questions by referring back to that statement.
But it's precisely the semantics of mutation that bothers me, which is
also what my questions were about.
> I don't believe that this would give me what I want if we adopt your
> value-only dynamic binding, but I have a different suggestion that should
> give both of us what we want: We adopt SRFI 39 now and generalize to
> threads later by having make-parameter do what Chez Scheme's
> make-thread-parameter currently does.
No, it wouldn't, because if I link to somebody else's code that uses
mutation behind the scenes, modularity is lost. I also really like
the API.
Here's a countersuggestion: We adopt a simple API than SRFI 39 with an
opaque representation for parameters, without mutation. It could be
just like SRFI 39, with the exception that dereference gets its own
operation:
(parameter-ref param)
retrieves the value of param.
Mutation can then be specified via (probably several different) SRFIs,
and/or you can implement a Chez-specific extension which gives you
what you want.
--
Cheers =8-} Mike
Friede, V?lkerverst?ndigung und ?berhaupt blabla
Received on Mon Feb 19 2007 - 04:27:20 UTC