Hoogle Search

Within LTS Haskell 24.68 (ghc-9.10.3)

Note that Stackage only displays results for the latest LTS and Nightly snapshot. Learn more.

  1. class Monad m => MonadReader r (m :: Type -> Type) | m -> r

    can-i-haz Control.Monad.Reader.Has

    See examples in Control.Monad.Reader. Note, the partially applied function type (->) r is a simple reader monad. See the instance declaration below.

  2. mapReader :: (a -> b) -> Reader r a -> Reader r b

    can-i-haz Control.Monad.Reader.Has

    Transform the value returned by a Reader.

  3. mapReaderT :: (m a -> n b) -> ReaderT r m a -> ReaderT r n b

    can-i-haz Control.Monad.Reader.Has

    Transform the computation inside a ReaderT.

  4. runReader :: Reader r a -> r -> a

    can-i-haz Control.Monad.Reader.Has

    Runs a Reader and extracts the final value from it. (The inverse of reader.)

  5. runReaderT :: ReaderT r (m :: Type -> Type) a -> r -> m a

    can-i-haz Control.Monad.Reader.Has

    No documentation available.

  6. withReader :: (r' -> r) -> Reader r a -> Reader r' a

    can-i-haz Control.Monad.Reader.Has

    Execute a computation in a modified environment (a specialization of withReaderT).

  7. withReaderT :: forall r' r (m :: Type -> Type) a . (r' -> r) -> ReaderT r m a -> ReaderT r' m a

    can-i-haz Control.Monad.Reader.Has

    Execute a computation in a modified environment (a more general version of local).

  8. class (Monad m, HasSource tag r m) => HasReader (tag :: k) r (m :: Type -> Type) | tag m -> r

    capability Capability.Reader

    Reader capability An instance should fulfill the following laws. At this point these laws are not definitive, see https://github.com/haskell/mtl/issues/5.

    k <*> ask @t = ask @t <**> k
    
    ask @t *> m = m = m <* ask @t
    
    local @t f (ask @t) = fmap f (ask @t)
    
    local @t f . local @t g = local @t (g . f)
    
    local @t f (pure x) = pure x
    
    local @t f (m >>= \x -> k x) = local @t f m >>= \x -> local @t f (k x)
    
    reader @t f = f <$> ask @t
    

  9. type HasReader' (tag :: k) = HasReader tag TypeOf k tag

    capability Capability.Reader

    Type synonym using the TypeOf type family to specify HasReader constraints without having to specify the type associated to a tag.

  10. newtype MonadReader (m :: Type -> Type) a

    capability Capability.Reader

    Derive HasSource from m's MonadReader instance.

Page 752 of many | Previous | Next