|
| Control.Concurrent.Session.SessionType |
|
|
| Description |
This module is concerned with allowing you to describe a session
type. A session type is treated as a table or 2D array, where each
row represents a particular session type function which can refer,
by index, to the other rows.
Basically, what you have here is the ability to describe a
program at the type level.
Just look at Control.Concurrent.Session.Tests for examples
|
|
|
| Documentation |
|
|
| Constructors | | Instances | |
|
|
|
|
|
|
|
|
| data SendPid inverted lst | Source |
|
| Constructors | | Instances | |
|
|
| data RecvPid inverted lst | Source |
|
| Constructors | | Instances | |
|
|
|
|
|
|
| data SendSession inverted idx | Source |
|
| Constructors | | Instances | | (Outgoing current ~ outgoing, Outgoing current' ~ incoming, Dual prog prog', Expand prog' frag current, Dual frag frag', Expand prog' frag' current') => ExpandSession prog (SendSession True frag) (Send ((,) SpecialSession (SessionState prog' prog ((,,) current outgoing incoming)))) | | (Outgoing current ~ outgoing, Outgoing current' ~ incoming, Dual prog prog', Expand prog frag current, Dual frag frag', Expand prog frag' current') => ExpandSession prog (SendSession False frag) (Send ((,) SpecialSession (SessionState prog prog' ((,,) current outgoing incoming)))) | | (Show inverted, Show idx) => Show (SendSession inverted idx) | | SValidSessionType idx => SNonTerminal (SendSession inverted idx) | | SNoJumpsBeyond l idx => SNoJumpsBeyond (SendSession inverted l) idx | | Not inverted inverted' => Dual (RecvSession inverted idx) (SendSession inverted' idx) | | Not inverted inverted' => Dual (SendSession inverted idx) (RecvSession inverted' idx) |
|
|
|
| data RecvSession inverted idx | Source |
|
| Constructors | | Instances | | (Outgoing current ~ outgoing, Outgoing current' ~ incoming, Dual prog prog', Expand prog' frag current, Dual frag frag', Expand prog' frag' current') => ExpandSession prog (RecvSession True frag) (Recv ((,) SpecialSession (SessionState prog' prog ((,,) current outgoing incoming)))) | | (Outgoing current ~ outgoing, Outgoing current' ~ incoming, Dual prog prog', Expand prog frag current, Dual frag frag', Expand prog frag' current') => ExpandSession prog (RecvSession False frag) (Recv ((,) SpecialSession (SessionState prog prog' ((,,) current outgoing incoming)))) | | (Show inverted, Show idx) => Show (RecvSession inverted idx) | | SValidSessionType idx => SNonTerminal (RecvSession inverted idx) | | SNoJumpsBeyond l idx => SNoJumpsBeyond (RecvSession inverted l) idx | | Not inverted inverted' => Dual (RecvSession inverted idx) (SendSession inverted' idx) | | Not inverted inverted' => Dual (SendSession inverted idx) (RecvSession inverted' idx) |
|
|
|
|
| Constructors | | Instances | | (Outgoing current ~ outgoing, Outgoing current' ~ incoming, Dual prog prog', Expand prog' frag current, Dual frag frag', Expand prog' frag' current') => ExpandSession prog (SendSession True frag) (Send ((,) SpecialSession (SessionState prog' prog ((,,) current outgoing incoming)))) | | (Outgoing current ~ outgoing, Outgoing current' ~ incoming, Dual prog prog', Expand prog frag current, Dual frag frag', Expand prog frag' current') => ExpandSession prog (SendSession False frag) (Send ((,) SpecialSession (SessionState prog prog' ((,,) current outgoing incoming)))) | | (Dual prog prog', BuildInvertedSessionsSet idxs invertedSessions, BuildPidTyMap prog' idxs (TyMap sessionsToIdx idxsToPairStructs)) => ExpandPid prog (SendPid True idxs) (Send ((,) SpecialPid (Pid prog' prog invertedSessions sessionsToIdx idxsToPairStructs))) | | (Dual prog prog', BuildInvertedSessionsSet idxs invertedSessions, BuildPidTyMap prog idxs (TyMap sessionsToIdx idxsToPairStructs)) => ExpandPid prog (SendPid False idxs) (Send ((,) SpecialPid (Pid prog prog' invertedSessions sessionsToIdx idxsToPairStructs))) | | SNonTerminal (Send t) | | SNoJumpsBeyond (Send t) idx | | Dual (Recv t) (Send t) | | Dual (Send t) (Recv t) | | NextSend (Cons (Send ((,) sp t)) nxt) (Send ((,) sp t)) nxt |
|
|
|
|
| Constructors | | Instances | | (Outgoing current ~ outgoing, Outgoing current' ~ incoming, Dual prog prog', Expand prog' frag current, Dual frag frag', Expand prog' frag' current') => ExpandSession prog (RecvSession True frag) (Recv ((,) SpecialSession (SessionState prog' prog ((,,) current outgoing incoming)))) | | (Outgoing current ~ outgoing, Outgoing current' ~ incoming, Dual prog prog', Expand prog frag current, Dual frag frag', Expand prog frag' current') => ExpandSession prog (RecvSession False frag) (Recv ((,) SpecialSession (SessionState prog prog' ((,,) current outgoing incoming)))) | | (Dual prog prog', BuildInvertedSessionsSet idxs invertedSessions, BuildPidTyMap prog' idxs (TyMap sessionsToIdx idxsToPairStructs)) => ExpandPid prog (RecvPid True idxs) (Recv ((,) SpecialPid (Pid prog' prog invertedSessions sessionsToIdx idxsToPairStructs))) | | (Dual prog prog', BuildInvertedSessionsSet idxs invertedSessions, BuildPidTyMap prog idxs (TyMap sessionsToIdx idxsToPairStructs)) => ExpandPid prog (RecvPid False idxs) (Recv ((,) SpecialPid (Pid prog prog' invertedSessions sessionsToIdx idxsToPairStructs))) | | SNonTerminal (Recv t) | | SNoJumpsBeyond (Recv t) idx | | RecvOrOffer (Recv ((,) sp t)) t cur' inc' | | Dual (Recv t) (Send t) | | Dual (Send t) (Recv t) |
|
|
|
|
| Constructors | | Instances | |
|
|
|
|
|
| Constructors | | Select :: lstOfLabels -> Select lstOfLabels | |
| Instances | |
|
|
|
|
|
| Constructors | | Offer :: lstOfLabels -> Offer lstOfLabels | |
| Instances | |
|
|
|
|
| class Dual a b | a -> b, b -> a where | Source |
|
| | Associated Types | | | | Methods | | | Instances | |
|
|
|
| Instances | |
|
|
| class SListOfSessionTypes lstOfLists | Source |
|
| Instances | |
|
|
|
| Instances | |
|
|
|
| Instances | |
|
|
| class SValidSessionType lst | Source |
|
| Instances | |
|
|
|
|
|
|
| class SNoJumpsBeyond s idx | Source |
|
| Instances | |
|
|
| class MakeListOfJumps x y | x -> y where | Source |
|
| | Methods | | makeListOfJumps :: x -> y | Source |
|
| | Instances | |
|
|
| class SWellFormedConfig idxA idxB ss | Source |
|
|
|
|
|
|
| Constructors | | Choice :: lstOfLabels -> Choice lstOfLabels | |
| Instances | |
|
|
| type family Outgoing frag | Source |
|
|
| class Expand prog frag expanded | prog frag -> expanded | Source |
|
| | Associated Types | | | | Methods | | | Instances | |
|
|
| Produced by Haddock version 2.4.2 |