HORIZON HASKELLDocslts/ghc-10.0.x8174fa42026-10-11Search names, modules, packages, or :: a typeCtrl K

GHC 10.0.0.20260917 · lts/ghc-10.0.x · 8174fa4 · 2026-10-11

Moduletransformers-0.6.3.0Haskell2010

Control.Monad.Trans.Maybe

The MaybeT monad transformer extends a monad with the ability to exit the computation without returning a value.

A sequence of actions produces a value only if all the actions in the sequence do. If one exits, the rest of the sequence is skipped and the composite action exits.

For a variant allowing a range of exception values, see Control.Monad.Trans.Except.

  • 1 type
  • 8 values

The MaybeT monad transformer

2 declarations
newtypenewtype MaybeT (m :: Type -> Type) a
#

The parameterizable maybe monad, a strict monad obtained by composing an arbitrary monad with the Maybe monad.

Computations are actions that may produce a value or exit.

The return function yields a computation that produces that value, while >>= sequences two subcomputations, exiting if either computation does.

Constructors

Instances25MonadTrans, Generic1, Monad, Functor, MonadFix, MonadFail, …

Monad transformations

3 declarations

Lifting other operations

4 declarations