[Haskell-cafe] Re: Asynchronous exception wormholes kill modularity

Bertram Felgenhauer bertram.felgenhauer at googlemail.com
Wed Apr 21 10:47:10 EDT 2010

Isaac Dupree wrote:
> [forkIOWithUnblock in the implementation of 'timeout'?] I thought
> that System.Timeout.timeout runs the IO in the original thread for a
> good reason. [...]

I brought up that implementation of timeout, as a non-trivial motivating
example for the need of a primitive like forkIOWithUnblock. Nobody has
suggested changing System.Timeout.timeout to use it - that would be a
different discussion.

Perhaps I should've picked a different example to avoid this confusion.

The argument is just that forkIOWithUnblock is needed in general, for
libraries who want to spawn and kill threads privately and may be called
with exceptions blocked.


More information about the Libraries mailing list