module Data.Functor.ProductIsomorphic.Class
( ProductIsoFunctor (..)
, ProductIsoApplicative (..)
, ProductIsoAlternative (..)
) where
import Data.Functor.ProductIsomorphic.Unsafe (ProductConstructor)
class ProductIsoFunctor f where
(|$|) :: ProductConstructor (a -> b) => (a -> b) -> f a -> f b
class ProductIsoFunctor f => ProductIsoApplicative f where
pureP :: ProductConstructor a => a -> f a
(|*|) :: f (a -> b) -> f a -> f b
class ProductIsoApplicative f => ProductIsoAlternative f where
emptyP :: f a
(|||) :: f a -> f a -> f a
infixl 4 |$|, |*|
infixl 3 |||