Re:Chicken Scheme
by rayiner on Friday March 15, 2013 @06:26PM
(#5383370)
> Any time you have closures you have threading issues. Think: if two threads call the same closure concurrently, how do they synchronize access to closed variables?
> To get what you want in a Lisp
Several Common Lisp implementations expose pthreads-style shared memory threads (SBCL, ECL, Clozure, Allegro, etc). It works just fine. The problem of synchronizing access to the closed-over variables in a closure is precisely the same as the problem of synchronizing access to instance variables of a class, and has the same solution: use a mutex.
> To get what you want in a Lisp
Several Common Lisp implementations expose pthreads-style shared memory threads (SBCL, ECL, Clozure, Allegro, etc). It works just fine. The problem of synchronizing access to the closed-over variables in a closure is precisely the same as the problem of synchronizing access to instance variables of a class, and has the same solution: use a mutex.