
On Fri, 2008-07-18 at 13:55 +0100, Simon Marlow wrote:
I've just submitted a proposal for a new signal-handling API, the ticket is here:
http://hackage.haskell.org/trac/ghc/ticket/2451
Deadline: 1 Aug (2 weeks).
I'm happy with it. It's relatively simple now (earlier iterations had more states). The main question is if it's too simple. Can people who know about and use signals take a look and see if it covers everything? I'm cc'ing a couple more people who know about and use signals. In particular, one simplification we made from an earlier design is that it's not possible to go back to the default OS signal action without explicitly removing all handlers. Previously there was a set of handlers and an independent signal state, ignore, default or handled. Now the state follows the set of handlers so when the set is empty then we get the default signal action. There is no ignore state as such but one can override the default handler by adding a handler that does nothing. So each handler is relatively independent. You can't interfere with another handler unless you have access to its HandlerId. That would seem to be a good thing but I might be missing some use case. Duncan