notmuch-0.3.0.0: Haskell binding to Notmuch, the mail indexer

Safe HaskellSafe
LanguageHaskell2010

Notmuch.Util

Description

Stuff that we don't want to export by default, but that we do want to expose in the library interface.

Synopsis

Documentation

type Prism s t a b = forall p f. (Choice p, Applicative f) => p a (f b) -> p s (f t) Source #

type Prism' s a = Prism s s a a Source #

type Lens' a b = forall f. Functor f => (b -> f b) -> a -> f a Source #

review :: MonadReader b m => Prism' t b -> m t Source #

bracketT :: (MonadError e m, MonadIO m) => ExceptT e IO a -> (a -> ExceptT e IO b) -> (a -> ExceptT e IO c) -> m c Source #

Variant of bracket that works with ExceptT and allows resource acquisition to fail, propagating the error. If resource finalisation fails, the error is discarded.