|
1 | 1 | # Module Documentation |
2 | 2 |
|
| 3 | +## Module Control.Comonad.Env |
| 4 | + |
| 5 | +### Types |
| 6 | + |
| 7 | + type Env e = EnvT e Identity |
| 8 | + |
| 9 | + |
| 10 | +### Values |
| 11 | + |
| 12 | + env :: forall e a. e -> a -> Env e a |
| 13 | + |
| 14 | + mapEnv :: forall e a b. (a -> b) -> Env e a -> Env e b |
| 15 | + |
| 16 | + runEnv :: forall e a. Env e a -> Tuple e a |
| 17 | + |
| 18 | + withEnv :: forall e1 e2 a. (e1 -> e2) -> Env e1 a -> Env e2 a |
| 19 | + |
| 20 | + |
| 21 | +## Module Control.Comonad.Env.Class |
| 22 | + |
| 23 | +### Type Classes |
| 24 | + |
| 25 | + class (Comonad w) <= ComonadEnv e w where |
| 26 | + ask :: forall a. w a -> e |
| 27 | + local :: forall a. (e -> e) -> w a -> w a |
| 28 | + |
| 29 | + |
| 30 | +### Type Class Instances |
| 31 | + |
| 32 | + instance comonadEnvEnvT :: (Comonad w) => ComonadEnv e (EnvT e w) |
| 33 | + |
| 34 | + instance comonadEnvTuple :: ComonadEnv e (Tuple e) |
| 35 | + |
| 36 | + |
| 37 | +### Values |
| 38 | + |
| 39 | + asks :: forall e1 e2 w a. (ComonadEnv e1 w) => (e1 -> e2) -> w e1 -> e2 |
| 40 | + |
| 41 | + |
| 42 | +## Module Control.Comonad.Env.Trans |
| 43 | + |
| 44 | +### Types |
| 45 | + |
| 46 | + newtype EnvT e w a where |
| 47 | + EnvT :: Tuple e (w a) -> EnvT e w a |
| 48 | + |
| 49 | + |
| 50 | +### Type Class Instances |
| 51 | + |
| 52 | + instance comonadEnvT :: (Comonad w) => Comonad (EnvT e w) |
| 53 | + |
| 54 | + instance comonadTransEnvT :: ComonadTrans (EnvT e) |
| 55 | + |
| 56 | + instance extendEnvT :: (Extend w) => Extend (EnvT e w) |
| 57 | + |
| 58 | + instance functorEnvT :: (Functor w) => Functor (EnvT e w) |
| 59 | + |
| 60 | + |
| 61 | +### Values |
| 62 | + |
| 63 | + mapEnvT :: forall e w1 w2 a b. (w1 a -> w2 b) -> EnvT e w1 a -> EnvT e w2 b |
| 64 | + |
| 65 | + runEnvT :: forall e w a. EnvT e w a -> Tuple e (w a) |
| 66 | + |
| 67 | + withEnvT :: forall e1 e2 w a. (e1 -> e2) -> EnvT e1 w a -> EnvT e2 w a |
| 68 | + |
| 69 | + |
| 70 | +## Module Control.Comonad.Store |
| 71 | + |
| 72 | +### Types |
| 73 | + |
| 74 | + type Store s a = StoreT s Identity a |
| 75 | + |
| 76 | + |
| 77 | +### Values |
| 78 | + |
| 79 | + runStore :: forall s a. Store s a -> Tuple (s -> a) s |
| 80 | + |
| 81 | + store :: forall s a. (s -> a) -> s -> Store s a |
| 82 | + |
| 83 | + |
| 84 | +## Module Control.Comonad.Store.Class |
| 85 | + |
| 86 | +### Type Classes |
| 87 | + |
| 88 | + class (Comonad w) <= ComonadStore s w where |
| 89 | + pos :: forall a. w a -> s |
| 90 | + peek :: forall a. s -> w a -> a |
| 91 | + |
| 92 | + |
| 93 | +### Type Class Instances |
| 94 | + |
| 95 | + instance comonadStoreStoreT :: (Comonad w) => ComonadStore s (StoreT s w) |
| 96 | + |
| 97 | + |
| 98 | +### Values |
| 99 | + |
| 100 | + experiment :: forall f a w s. (ComonadStore s w, Functor f) => (s -> f s) -> w a -> f a |
| 101 | + |
| 102 | + peeks :: forall s a w. (ComonadStore s w) => (s -> s) -> w a -> a |
| 103 | + |
| 104 | + seek :: forall s a w. (ComonadStore s w, Extend w) => s -> w a -> w a |
| 105 | + |
| 106 | + seeks :: forall s a w. (ComonadStore s w, Extend w) => (s -> s) -> w a -> w a |
| 107 | + |
| 108 | + |
| 109 | +## Module Control.Comonad.Store.Trans |
| 110 | + |
| 111 | +### Types |
| 112 | + |
| 113 | + newtype StoreT s w a where |
| 114 | + StoreT :: Tuple (w (s -> a)) s -> StoreT s w a |
| 115 | + |
| 116 | + |
| 117 | +### Type Class Instances |
| 118 | + |
| 119 | + instance comonadStoreT :: (Comonad w) => Comonad (StoreT s w) |
| 120 | + |
| 121 | + instance comonadTransStoreT :: ComonadTrans (StoreT s) |
| 122 | + |
| 123 | + instance extendStoreT :: (Extend w) => Extend (StoreT s w) |
| 124 | + |
| 125 | + instance functorStoreT :: (Functor w) => Functor (StoreT s w) |
| 126 | + |
| 127 | + |
| 128 | +### Values |
| 129 | + |
| 130 | + runStoreT :: forall s w a. StoreT s w a -> Tuple (w (s -> a)) s |
| 131 | + |
| 132 | + |
| 133 | +## Module Control.Comonad.Traced |
| 134 | + |
| 135 | +### Types |
| 136 | + |
| 137 | + type Traced m = TracedT m Identity |
| 138 | + |
| 139 | + |
| 140 | +### Values |
| 141 | + |
| 142 | + runTraced :: forall m a. Traced m a -> m -> a |
| 143 | + |
| 144 | + traced :: forall m a. (m -> a) -> Traced m a |
| 145 | + |
| 146 | + |
| 147 | +## Module Control.Comonad.Traced.Class |
| 148 | + |
| 149 | +### Type Classes |
| 150 | + |
| 151 | + class (Comonad w) <= ComonadTraced t w where |
| 152 | + track :: forall a. t -> w a -> a |
| 153 | + |
| 154 | + |
| 155 | +### Type Class Instances |
| 156 | + |
| 157 | + instance comonadTracedTracedT :: (Comonad w, Monoid t) => ComonadTraced t (TracedT t w) |
| 158 | + |
| 159 | + |
| 160 | +### Values |
| 161 | + |
| 162 | + censor :: forall w a t b. (Functor w) => (t -> t) -> TracedT t w a -> TracedT t w a |
| 163 | + |
| 164 | + listen :: forall w a t. (Functor w) => TracedT t w a -> TracedT t w (Tuple a t) |
| 165 | + |
| 166 | + listens :: forall w a t b. (Functor w) => (t -> b) -> TracedT t w a -> TracedT t w (Tuple a b) |
| 167 | + |
| 168 | + tracks :: forall w a t. (Comonad w, ComonadTraced t w) => (a -> t) -> w a -> a |
| 169 | + |
| 170 | + |
| 171 | +## Module Control.Comonad.Traced.Trans |
| 172 | + |
| 173 | +### Types |
| 174 | + |
| 175 | + newtype TracedT t w a where |
| 176 | + TracedT :: w (t -> a) -> TracedT t w a |
| 177 | + |
| 178 | + |
| 179 | +### Type Class Instances |
| 180 | + |
| 181 | + instance comonadTracedT :: (Comonad w, Monoid t) => Comonad (TracedT t w) |
| 182 | + |
| 183 | + instance comonadTransTracedT :: (Monoid t) => ComonadTrans (TracedT t) |
| 184 | + |
| 185 | + instance extendTracedT :: (Extend w, Semigroup t) => Extend (TracedT t w) |
| 186 | + |
| 187 | + instance functorTracedT :: (Functor w) => Functor (TracedT t w) |
| 188 | + |
| 189 | + |
| 190 | +### Values |
| 191 | + |
| 192 | + runTracedT :: forall w a t. TracedT t w a -> w (t -> a) |
| 193 | + |
| 194 | + |
| 195 | +## Module Control.Comonad.Trans |
| 196 | + |
| 197 | +### Type Classes |
| 198 | + |
| 199 | + class ComonadTrans f where |
| 200 | + lower :: forall w a. (Comonad w) => f w a -> w a |
| 201 | + |
| 202 | + |
3 | 203 | ## Module Control.Monad.Cont.Class |
4 | 204 |
|
5 | 205 | ### Type Classes |
|
35 | 235 |
|
36 | 236 | instance applicativeContT :: (Functor m, Monad m) => Applicative (ContT r m) |
37 | 237 |
|
38 | | - instance appluContT :: (Functor m, Monad m) => Apply (ContT r m) |
| 238 | + instance applyContT :: (Functor m, Monad m) => Apply (ContT r m) |
39 | 239 |
|
40 | 240 | instance bindContT :: (Monad m) => Bind (ContT r m) |
41 | 241 |
|
|
109 | 309 |
|
110 | 310 | instance alternativeErrorT :: (Monad m, Error e) => Alternative (ErrorT e m) |
111 | 311 |
|
112 | | - instance applicativeErrorT :: (Functor m, Monad m) => Applicative (ErrorT e m) |
| 312 | + instance applicativeErrorT :: (Applicative m) => Applicative (ErrorT e m) |
113 | 313 |
|
114 | | - instance applyErrorT :: (Functor m, Monad m) => Apply (ErrorT e m) |
| 314 | + instance applyErrorT :: (Apply m) => Apply (ErrorT e m) |
115 | 315 |
|
116 | 316 | instance bindErrorT :: (Monad m, Error e) => Bind (ErrorT e m) |
117 | 317 |
|
|
0 commit comments