Re: [racket-users] Re: Re-entrant parameterize modification isolation when using shift/reset

2021-07-31 Thread Matthew Flatt
At Fri, 30 Jul 2021 12:56:37 -0700 (PDT), Greg Rosenblatt wrote: > Is the `parameter * thread * parameterization -> box` part implemented as > something like a global weak-hash, or is it built directly into the stack > representation? A parameter holds a key and a thread cell, where the thread

Re: [racket-users] Re: Re-entrant parameterize modification isolation when using shift/reset

2021-07-30 Thread Greg Rosenblatt
Thanks, I think that makes sense. Is the `parameter * thread * parameterization -> box` part implemented as something like a global weak-hash, or is it built directly into the stack representation? Continuing the other conversation for a moment with a code reference to explain to my future

Re: [racket-users] Re: Re-entrant parameterize modification isolation when using shift/reset

2021-07-30 Thread Matthew Flatt
At Sun, 25 Jul 2021 10:35:00 -0700 (PDT), Greg Rosenblatt wrote: > I was surprised that subsequent re-entries can observe modifications from > the earlier ones, since my mental model of dynamic parameters was that > their values were retrieved from a fresh dynamic calling context, whose >

[racket-users] Re: Re-entrant parameterize modification isolation when using shift/reset

2021-07-29 Thread Greg Rosenblatt
Thanks for the response, Jack. I'm looking at: https://docs.racket-lang.org/reference/contmarks.html I don't see a way to update the value of an existing key without installing a new mark. Is it possible to do that? Parameters allow you to update the value associated with the innermost use

[racket-users] Re: Re-entrant parameterize modification isolation when using shift/reset

2021-07-29 Thread jackh...@gmail.com
I don't fully follow the example you gave because I'm not super familiar with shift/reset, but would using continuation marks directly instead of parameters work for your use case? Continuation marks work like what you described, where data is stored directly on the stack rather than in a