AFSM-0.1.3.1: Arrowized functional state machines

Copyright(c) Hanzhong Xu, Meng Meng 2016,
LicenseMIT License
Maintainerhanzh.xu@gmail.com
Stabilityexperimental
Portabilityportable
Safe HaskellSafe
LanguageHaskell2010

Control.AFSM.SMH

Contents

Description

 

Synopsis

Documentation

newSMH :: (() -> a -> (SMH a b, b)) -> SMH a b Source #

the same constructor with newSM

simpleSMH :: (s -> a -> (s, b)) -> s -> SMH a b Source #

the same constructor with simpleSM

hideStorage :: SM s a b -> SMH a b Source #

hide the Storage type in the transition function.

Orphan instances

Arrow (SM ()) Source # 

Methods

arr :: (b -> c) -> SM () b c #

first :: SM () b c -> SM () (b, d) (c, d) #

second :: SM () b c -> SM () (d, b) (d, c) #

(***) :: SM () b c -> SM () b' c' -> SM () (b, b') (c, c') #

(&&&) :: SM () b c -> SM () b c' -> SM () b (c, c') #

ArrowChoice (SM ()) Source # 

Methods

left :: SM () b c -> SM () (Either b d) (Either c d) #

right :: SM () b c -> SM () (Either d b) (Either d c) #

(+++) :: SM () b c -> SM () b' c' -> SM () (Either b b') (Either c c') #

(|||) :: SM () b d -> SM () c d -> SM () (Either b c) d #

ArrowApply (SM ()) Source # 

Methods

app :: SM () (SM () b c, b) c #

ArrowLoop (SM ()) Source # 

Methods

loop :: SM () (b, d) (c, d) -> SM () b c #

Category * (SM ()) Source # 

Methods

id :: cat a a #

(.) :: cat b c -> cat a b -> cat a c #