Software Transactional Memory ----------------------------- GHC now supports a new way to coordinate the activities of Concurrent Haskell threads, called Software Transactional Memory (STM). The `STM papers `__ are an excellent introduction to what STM is, and how to use it. The main library you need to use is the `stm library `__. The main features supported are these: - Atomic blocks. - Transactional variables. - Operations for composing transactions: ``retry``, and ``orElse``. - Data invariants. All these features are described in the papers mentioned earlier.