comonad-4.0: Comonads

Portability | non-portable (fundeps, MPTCs)
Stability | experimental
Maintainer | Edward Kmett <ekmett@gmail.com>
Safe Haskell | Trustworthy

Control.Comonad.Store.Class

Description

# Documentation

class Comonad w => ComonadStore s w | w -> s where Source

Methods

pos :: w a -> sSource

peek :: s -> w a -> aSource

peeks :: (s -> s) -> w a -> aSource

seek :: s -> w a -> w aSource

seeks :: (s -> s) -> w a -> w aSource

experiment :: Functor f => (s -> f s) -> w a -> f aSource

Instances

ComonadStore s w => ComonadStore s (IdentityT w) |
(ComonadStore s w, Monoid m) => ComonadStore s (TracedT m w) |
ComonadStore s w => ComonadStore s (EnvT e w) |
Comonad w => ComonadStore s (StoreT s w) |

lowerPos :: (ComonadTrans t, ComonadStore s w) => t w a -> sSource

lowerPeek :: (ComonadTrans t, ComonadStore s w) => s -> t w a -> aSource