Portability | portable |
---|---|
Stability | stable |
Maintainer | [email protected] |
Control.Async
Description
An implementation of IO computations that return their value asynchronously.
Documentation
Async a
represents a value a
that is being computed
asynchronously, i.e. a value that is going to become available at
some point in the future.
throwToAsync :: Exception e => Async a -> e -> IO ()Source
Throw an asynchronous exception to the thread that performs the computation associated with this value.
isReadyAsync :: Async a -> IO BoolSource
Test whether the asynchronous value has become available.
waitForAsync :: Async a -> IO aSource
Wait for the asynchronous value to become available, and retrieve it. If the computation that generated the value has thrown an exception, then that exception will be raised here.