bifunctors-5.5: Bifunctors

Safe HaskellSafe
LanguageHaskell98

Data.Bifunctor.Sum

Documentation

data Sum p q a b Source #

Constructors

L2 (p a b) 
R2 (q a b) 

Instances

BifunctorFunctor k k1 k k1 (Sum k k1 p) Source # 

Methods

bifmap :: (k :-> k) p q -> (Sum k k1 p :-> k) (t p) (t q) Source #

BifunctorMonad k k1 (Sum k k1 p) Source # 

Methods

bireturn :: p a b -> t p a b Source #

bibind :: (Sum k k1 p :-> k) p (t q) -> (Sum k k1 p :-> k) (t p) (t q) Source #

bijoin :: t (t p) a b -> t p a b Source #

(Bifunctor p, Bifunctor q) => Bifunctor (Sum * * p q) Source # 

Methods

bimap :: (a -> b) -> (c -> d) -> Sum * * p q a c -> Sum * * p q b d #

first :: (a -> b) -> Sum * * p q a c -> Sum * * p q b c #

second :: (b -> c) -> Sum * * p q a b -> Sum * * p q a c #

(Bifoldable p, Bifoldable q) => Bifoldable (Sum * * p q) Source # 

Methods

bifold :: Monoid m => Sum * * p q m m -> m Source #

bifoldMap :: Monoid m => (a -> m) -> (b -> m) -> Sum * * p q a b -> m Source #

bifoldr :: (a -> c -> c) -> (b -> c -> c) -> c -> Sum * * p q a b -> c Source #

bifoldl :: (c -> a -> c) -> (c -> b -> c) -> c -> Sum * * p q a b -> c Source #

(Bitraversable p, Bitraversable q) => Bitraversable (Sum * * p q) Source # 

Methods

bitraverse :: Applicative f => (a -> f c) -> (b -> f d) -> Sum * * p q a b -> f (Sum * * p q c d) Source #

Generic1 (Sum * k p q a) Source # 

Associated Types

type Rep1 (Sum * k p q a :: * -> *) :: * -> * #

Methods

from1 :: Sum * k p q a a -> Rep1 (Sum * k p q a) a #

to1 :: Rep1 (Sum * k p q a) a -> Sum * k p q a a #

(Eq (q a b), Eq (p a b)) => Eq (Sum k1 k p q a b) Source # 

Methods

(==) :: Sum k1 k p q a b -> Sum k1 k p q a b -> Bool #

(/=) :: Sum k1 k p q a b -> Sum k1 k p q a b -> Bool #

(Ord (q a b), Ord (p a b)) => Ord (Sum k1 k p q a b) Source # 

Methods

compare :: Sum k1 k p q a b -> Sum k1 k p q a b -> Ordering #

(<) :: Sum k1 k p q a b -> Sum k1 k p q a b -> Bool #

(<=) :: Sum k1 k p q a b -> Sum k1 k p q a b -> Bool #

(>) :: Sum k1 k p q a b -> Sum k1 k p q a b -> Bool #

(>=) :: Sum k1 k p q a b -> Sum k1 k p q a b -> Bool #

max :: Sum k1 k p q a b -> Sum k1 k p q a b -> Sum k1 k p q a b #

min :: Sum k1 k p q a b -> Sum k1 k p q a b -> Sum k1 k p q a b #

(Read (q a b), Read (p a b)) => Read (Sum k1 k p q a b) Source # 

Methods

readsPrec :: Int -> ReadS (Sum k1 k p q a b) #

readList :: ReadS [Sum k1 k p q a b] #

readPrec :: ReadPrec (Sum k1 k p q a b) #

readListPrec :: ReadPrec [Sum k1 k p q a b] #

(Show (q a b), Show (p a b)) => Show (Sum k1 k p q a b) Source # 

Methods

showsPrec :: Int -> Sum k1 k p q a b -> ShowS #

show :: Sum k1 k p q a b -> String #

showList :: [Sum k1 k p q a b] -> ShowS #

Generic (Sum k1 k p q a b) Source # 

Associated Types

type Rep (Sum k1 k p q a b) :: * -> * #

Methods

from :: Sum k1 k p q a b -> Rep (Sum k1 k p q a b) x #

to :: Rep (Sum k1 k p q a b) x -> Sum k1 k p q a b #

type Rep1 (Sum * k p q a) Source # 
type Rep1 (Sum * k p q a) = D1 (MetaData "Sum" "Data.Bifunctor.Sum" "bifunctors-5.5-32pcfa06LpVCOUG1IJODTZ" False) ((:+:) (C1 (MetaCons "L2" PrefixI False) (S1 (MetaSel (Nothing Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec1 (p a)))) (C1 (MetaCons "R2" PrefixI False) (S1 (MetaSel (Nothing Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec1 (q a)))))
type Rep (Sum k1 k p q a b) Source # 
type Rep (Sum k1 k p q a b) = D1 (MetaData "Sum" "Data.Bifunctor.Sum" "bifunctors-5.5-32pcfa06LpVCOUG1IJODTZ" False) ((:+:) (C1 (MetaCons "L2" PrefixI False) (S1 (MetaSel (Nothing Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (p a b)))) (C1 (MetaCons "R2" PrefixI False) (S1 (MetaSel (Nothing Symbol) NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 (q a b)))))