categories-1.0.7: Categories
Copyright2008 Edward Kmett
LicenseBSD
MaintainerEdward Kmett <ekmett@gmail.com>
Stabilityexperimental
Portabilitynon-portable (class-associated types)
Safe HaskellTrustworthy
LanguageHaskell2010

Control.Category.Cartesian.Closed

Description

 
Synopsis

Cartesian Closed Category

class Cartesian k => CCC (k :: Type -> Type -> Type) where Source #

A CCC has full-fledged monoidal finite products and exponentials

Associated Types

type Exp (k :: Type -> Type -> Type) :: Type -> Type -> Type Source #

Methods

apply :: k (Product k (Exp k a b) a) b Source #

curry :: k (Product k a b) c -> k a (Exp k b c) Source #

uncurry :: k a (Exp k b c) -> k (Product k a b) c Source #

Instances

Instances details
CCC (->) Source # 
Instance details

Defined in Control.Category.Cartesian.Closed

Associated Types

type Exp (->) 
Instance details

Defined in Control.Category.Cartesian.Closed

type Exp (->) = (->)

Methods

apply :: Product (->) (Exp (->) a b) a -> b Source #

curry :: (Product (->) a b -> c) -> a -> Exp (->) b c Source #

uncurry :: (a -> Exp (->) b c) -> Product (->) a b -> c Source #

unitCCC :: CCC k => k a (Exp k b (Product k b a)) Source #

counitCCC :: CCC k => k (Product k b (Exp k b a)) a Source #

Co-(Cartesian Closed Category)

class CoCartesian k => CoCCC (k :: Type -> Type -> Type) where Source #

A Co-CCC has full-fledged comonoidal finite coproducts and coexponentials

Associated Types

type Coexp (k :: Type -> Type -> Type) :: Type -> Type -> Type Source #

Methods

coapply :: k b (Sum k (Coexp k a b) a) Source #

cocurry :: k c (Sum k a b) -> k (Coexp k b c) a Source #

uncocurry :: k (Coexp k b c) a -> k c (Sum k a b) Source #

unitCoCCC :: CoCCC k => k a (Sum k b (Coexp k b a)) Source #

counitCoCCC :: CoCCC k => k (Coexp k b (Sum k b a)) a Source #