Tutorial by Topics: functor

Functor is the class of types f :: * -> * which can be covariantly mapped over. Mapping a function over a data structure applies the function to all the elements of the structure without changing the structure itself. A Functor can be thought of as a container for some value, or a computation c...
bimap :: (a -> b) -> (c -> d) -> p a c -> p b d first :: (a -> b) -> p a c -> p b c second :: (b -> c) -> p a b -> p a c A run of the mill Functor is covariant in a single type parameter. For instance, if f is a Functor, then given an f a, and a function ...
Applicative is the class of types f :: * -> * which allows lifted function application over a structure where the function is also embedded in that structure. Definition class Functor f => Applicative f where pure :: a -> f a (<*>) :: f (a -> b) -> f a -> f ...
Profunctor is a typeclass provided by the profunctors package in Data.Profunctor. See the "Remarks" section for a full explanation. dimap :: Profunctor p => (a -> b) -> (c -> d) -> p b c -> p a d lmap :: Profunctor p => (a -> b) -> p b c -> p a c rmap...

Page 1 of 1