A monad for managed values

Version on this page:1.0.9@rev:3
LTS Haskell 20.16:1.0.10
Stackage Nightly 2023-03-27:1.0.10
Latest on Hackage:1.0.10

See all snapshots managed appears in

BSD-3-Clause licensed by Gabriella Gonzalez
This version can be pinned in stack with:managed-1.0.9@sha256:c418d2284a3190e0e2b970d7963906d9a7a2f6edd617e334ed341f394649f004,1716

Module documentation for 1.0.9

Depends on 2 packages(full list with versions):
Used by 1 package in lts-20.9(full list with versions):

In Haskell you very often acquire values using the with... idiom using functions of type (a -> IO r) -> IO r. This idiom forms a Monad, which is a special case of the ContT monad (from transformers) or the Codensity monad (from kan-extensions). The main purpose behind this package is to provide a restricted form of these monads specialized to this unusually common case.

The reason this package defines a specialized version of these types is to:

  • be more beginner-friendly,

  • simplify inferred types and error messages, and:

  • provide some additional type class instances that would otherwise be orphan instances