[racket] How to execute all pending wills in a will-executor?

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Thu Apr 12 09:18:03 EDT 2012

At Thu, 12 Apr 2012 15:11:02 +0200, Stephan Houben wrote:
> Hi list,
> 
> Suppose I have a will-executor and I have arrived at a safe point.
> Now I want to execute any pending wills.
> 
> So my first idea is to repeatedly call will-try-execute until it returns #f.
> However, what if any of the wills itself returns #f ?
> Then the loop will terminate prematurely.

You could use `sync/timeout', instead, to poll the executor.

I see that the docs for will executors don't mention that they are
syncronizable events, and I'll fix that.


Posted on the users mailing list.