[r6rs-discuss] [Formal] eliminate library export immutability loophole

From: AndrevanTonder <andre>
Date: Sun Mar 18 10:07:11 2007

On Fri, 9 Mar 2007, R. Kent Dybvig wrote:

> The present description of libraries leaves open the possibility that a
> continuation grabbed within a variable definition's right-hand-side
> expression and subsequently invoked might cause the reinitialization, with
> different values, of some or all of the local counterparts of the exported
> variables, effecting implicit assignments to variables that are supposed
> to immutable.....

> Proposal:
>
> Add new wording to the effect that the continuation of the right-hand-side
> expression of a library variable definition should not be returned to more
> than once and that implementations either "should" or "must" raise an
> exception if this occurs.

Do you intend this to apply to all variable definitions or just to those that
are exported? It only seems natural for the latter case. If one is going to
apply this also to unexported definitions, the question arises as to why one
wouldn't apply it also to internal definitions in lambda bodies. I have not
been able to think of a good reason to treat the latter differently.

Regards
Andre
Received on Sun Mar 18 2007 - 10:06:33 UTC

This archive was generated by hypermail 2.3.0 : Wed Oct 23 2024 - 09:15:01 UTC