purescript-contrib / purescript-fork

An MTL-style class for monads that support forking
Apache License 2.0
8 stars 7 forks source link

Unlawful Aff Instance? #10

Closed eric-corumdigital closed 5 years ago

eric-corumdigital commented 5 years ago

Maybe I'm reading it wrong but the Aff instance for MonadKill seems to be incorrect.

suspend a >>= \f -> kill e f *> join f = throwError e

This is not the case for Aff. Joining on a killed fork is a panic. throwError uses the error channel, not the interrupt channel.