1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87
|
name: async
synopsis: Run IO operations asynchronously and wait for their results
description:
This package provides a higher-level interface over
threads, in which an @Async a@ is a concurrent
thread that will eventually deliver a value of
type @a@. The package provides ways to create
@Async@ computations, wait for their results, and
cancel them.
.
Using @Async@ is safer than using threads in two
ways:
.
* When waiting for a thread to return a result,
if the thread dies with an exception then the
caller must either re-throw the exception
('wait') or handle it ('waitCatch'); the
exception cannot be ignored.
.
* The API makes it possible to build a tree of
threads that are automatically killed when
their parent dies (see 'withAsync').
.
Changes in 2.0.1.5:
.
* Bump @base@ dependencies for GHC 7.8
.
Changes in 2.0.1.4:
.
* Bump @base@ dependency of test suite
.
Changes in 2.0.1.3:
.
* Bump @base@ dependency to allow 4.6
.
Changes in 2.0.1.2:
.
* Bump @stm@ dependency to 2.4
.
Changes in 2.0.1.1:
.
* Safe Haskell support: @Control.Concurrent.Async@ is now @Trustworthy@
.
Changes in 2.0.1.0:
.
* Added a @Functor@ instance for @Async@
.
* Added @asyncBound@, @asyncOn@, @asyncWithUnmask@, @asyncOnWithUnmask@, @withAsyncBound@, @withAsyncOn@, @withAsyncWithUnmask@, @withAsyncOnWithUnmask@.
.
* Added @mapConcurrently@
.
* Added @Concurrently@ (with @Applicative@ and @Alternative@ instances)
version: 2.0.1.5
license: BSD3
license-file: LICENSE
author: Simon Marlow
maintainer: Simon Marlow <marlowsd@gmail.com>
copyright: (c) Simon Marlow 2012
category: Concurrency
build-type: Simple
cabal-version: >=1.8
homepage: https://github.com/simonmar/async
bug-reports: https://github.com/simonmar/async/issues
tested-with: GHC==7.0.3, GHC==7.2.2, GHC==7.4.1
extra-source-files:
bench/race.hs
source-repository head
type: git
location: https://github.com/simonmar/async.git
library
exposed-modules: Control.Concurrent.Async
build-depends: base >= 4.3 && < 4.8, stm >= 2.2 && < 2.5
test-suite test-async
type: exitcode-stdio-1.0
hs-source-dirs: test
main-is: test-async.hs
build-depends: base >= 4.3 && < 4.8,
async,
test-framework,
test-framework-hunit,
HUnit
|