comonad-transformers-3.0.1: Comonad transformers

MaintainerEdward Kmett <>
Safe HaskellNone




The environment comonad transformer (aka coreader). This adds an extra value that can be accessed in the environment.

Left adjoint to the reader comonad.


The strict environment comonad

env :: e -> a -> Env e aSource

runEnv :: Env e a -> (e, a)Source

The strict environment comonad transformer

data EnvT e w a Source


EnvT e (w a) 


ComonadTrans (EnvT e) 
ComonadHoist (EnvT e) 
Functor w => Functor (EnvT e w) 
(Typeable s, Typeable1 w) => Typeable1 (EnvT s w) 
Foldable w => Foldable (EnvT e w) 
(Functor (EnvT e w), Foldable (EnvT e w), Traversable w) => Traversable (EnvT e w) 
(Functor (EnvT e w), Comonad w) => Comonad (EnvT e w) 
(Comonad (EnvT e w), Semigroup e, ComonadApply w) => ComonadApply (EnvT e w) 
(Functor (EnvT e w), Semigroup e, Apply w) => Apply (EnvT e w) 
(Functor (EnvT e w), Extend w) => Extend (EnvT e w) 
(Typeable (EnvT e w a), Data e, Typeable1 w, Data (w a), Data a) => Data (EnvT e w a) 
(Typeable s, Typeable1 w, Typeable a) => Typeable (EnvT s w a) 

runEnvT :: EnvT e w a -> (e, w a)Source

lowerEnvT :: EnvT e w a -> w aSource


ask :: EnvT e w a -> eSource

asks :: (e -> f) -> EnvT e w a -> fSource

local :: (e -> e) -> EnvT e w a -> EnvT e w aSource