concat-examples-0.3.0.0: Some examples of compiling to categories
Safe HaskellSafe-Inferred
LanguageHaskell2010

ConCat.Continuation

Description

Continuation-passing category

Documentation

newtype Cont k r a b Source #

Constructors

Cont ((b `k` r) -> a `k` r) 

Instances

Instances details
(MonoidalPCat k, CoproductPCat k, Ok k r, OkAdd k, Additive r) => BraidedPCat (Cont k r) Source # 
Instance details

Defined in ConCat.Continuation

Methods

swapP :: Ok2 (Cont k r) a b => Cont k r (Prod (Cont k r) a b) (Prod (Cont k r) b a) Source #

Category (Cont k r) Source # 
Instance details

Defined in ConCat.Continuation

Associated Types

type Ok (Cont k r) :: Type -> Constraint Source #

Methods

id :: Ok (Cont k r) a => Cont k r a a Source #

(.) :: forall b c a. Ok3 (Cont k r) a b c => Cont k r b c -> Cont k r a b -> Cont k r a c Source #

(MProductCat k, TerminalCat k, CoterminalCat k, CoproductPCat k, OkAdd k, Ok k r) => MonoidalPCat (Cont k r) Source # 
Instance details

Defined in ConCat.Continuation

Methods

(***) :: Ok4 (Cont k r) a b c d => Cont k r a c -> Cont k r b d -> Cont k r (Prod (Cont k r) a b) (Prod (Cont k r) c d) Source #

first :: forall a a' b. Ok3 (Cont k r) a b a' => Cont k r a a' -> Cont k r (Prod (Cont k r) a b) (Prod (Cont k r) a' b) Source #

second :: Ok3 (Cont k r) a b b' => Cont k r b b' -> Cont k r (Prod (Cont k r) a b) (Prod (Cont k r) a b') Source #

(ProductCat k, CoproductPCat k, AbelianCat k, OkAdd k, Ok k r) => ProductCat (Cont k r) Source # 
Instance details

Defined in ConCat.Continuation

Methods

exl :: Ok2 (Cont k r) a b => Cont k r (Prod (Cont k r) a b) a Source #

exr :: Ok2 (Cont k r) a b => Cont k r (Prod (Cont k r) a b) b Source #

dup :: Ok (Cont k r) a => Cont k r a (Prod (Cont k r) a a) Source #

(Zip h, IxCoproductPCat k h, Additive1 h, OkAdd k, Ok k r) => IxMonoidalPCat (Cont k r) h Source # 
Instance details

Defined in ConCat.Continuation

Methods

crossF :: Ok2 (Cont k r) a b => h (Cont k r a b) -> Cont k r (h a) (h b) Source #

(IxCoproductPCat k h, Zip h, Additive1 h, OkAdd k, Ok k r) => IxProductCat (Cont k r) h Source # 
Instance details

Defined in ConCat.Continuation

Methods

exF :: Ok (Cont k r) a => h (Cont k r (h a) a) Source #

forkF :: Ok2 (Cont k r) a b => h (Cont k r a b) -> Cont k r a (h b) Source #

replF :: Ok (Cont k r) a => Cont k r a (h a) Source #

(OkIxProd k h, Additive1 h, OkAdd k) => OkIxProd (Cont k r) h Source # 
Instance details

Defined in ConCat.Continuation

Methods

okIxProd :: Ok' (Cont k r) a |- Ok' (Cont k r) (h a) Source #

HasRep (Cont k r a b) Source # 
Instance details

Defined in ConCat.Continuation

Associated Types

type Rep (Cont k r a b) Source #

Methods

repr :: Cont k r a b -> Rep (Cont k r a b) Source #

abst :: Rep (Cont k r a b) -> Cont k r a b Source #

type Ok (Cont k r) Source # 
Instance details

Defined in ConCat.Continuation

type Ok (Cont k r) = Ok k
type Rep (Cont k r a b) Source # 
Instance details

Defined in ConCat.Continuation

type Rep (Cont k r a b) = k b r -> k a r

cont :: (Category k, Ok3 k r a b) => (a `k` b) -> Cont k r a b Source #