I agree that Racket parameters work very well.
FWIW the Racket parameters are inspired by:
"Processes vs. User-Level Threads in SCSH" by Martin Gasbichler and Michael Sperber
https://www.researchgate.net/publication/2546137_Processes_v...
FWIW the Racket parameters are inspired by:
"Processes vs. User-Level Threads in SCSH" by Martin Gasbichler and Michael Sperber
https://www.researchgate.net/publication/2546137_Processes_v...
What value does a forked thread get? The value at the dynamic scope of the parent at the point of thread creation.
What happens if a delimited continuation is invoked by a different thread compared to the one that created the continuation? If a parameterize call was made within the continuation's delimited extent, then it moves with the continuation. If not, it'll be in the executing thread. In either case the answer is consistent: The value within the dynamic extent of the continuation is used.
What happens to other threads if one overrides a parameter within its own dynamic scope? Nothing, threads don't have a dynamic scope relationship between them after thread creation.