fork package:slave-thread
Fork a slave thread to run a computation on.
Fork a slave thread with a finalizer action to run a computation on.
The finalizer gets executed when the thread dies for whatever reason:
due to being killed or an uncaught exception, or a normal termination.
Note the order of arguments:
forkFinally finalizer computation
Like
forkFinally, but provides the computation a function that
unmasks asynchronous exceptions. See
Note [Unmask] at the
bottom of this module.
Like
fork, but provides the computation a function that unmasks
asynchronous exceptions. See
Note [Unmask] at the bottom of
this module.