Safe Haskell | None |
---|---|
Language | Haskell98 |
- class MonadRegister tm => MonadRegisterRun tm where
- newtype Id = Id Int
- newtype Port a = Port {}
- data Inst t a where
- type Prog t = ProgramT (Inst t) (State (Seq Any))
- message :: (MonadRegister m, EffectM m ~ Prog t) => String -> m ()
- listen :: (MonadRegister m, EffectM m ~ Prog t, Show a) => Port a -> (a -> Modifier m ()) -> m ()
- data Inst' a where
- type Prog' = Program Inst'
- message' :: String -> ProgramT Inst' m ()
- error' :: String -> ProgramT Inst' m ()
- send :: Show a => Port a -> a -> ProgramT Inst' m ()
- getProg' :: Prog' b -> StateT s Er b
- type Er = Writer [Either (Either String String) String]
- tell_ :: MonadWriter [Either a b] m => b -> m ()
- fail' :: MonadWriter [Either (Either a b1) b] m => b1 -> m ()
- unfail :: MonadWriter [Either (Either a b1) b] m => a -> m ()
- handEr :: [Char] -> Writer [Either (Either [Char] [Char]) [Char]] () -> [[Char]]
- showRes :: [Char] -> ((), [Either (Either [Char] [Char]) [Char]]) -> [[Char]]
- data Any = forall x . Any x
- data Listener m = forall a . Show a => Listener {
- _listenerId :: Id
- _listenerPort :: Port a
- _listenerStatus :: RegionStatusChange
- _listenerCallback :: a -> Prog m ()
- listenerStatus :: forall m. Lens' (Listener m) RegionStatusChange
- listenerId :: forall m. Lens' (Listener m) Id
- data ST m = ST {
- _postponed :: [m]
- _listeners :: [Listener m]
- _idcounter :: Int
- _vars :: Seq Any
- vars :: forall m. Lens' (ST m) (Seq Any)
- postponed :: forall m. Lens' (ST m) [m]
- listeners :: forall m. Lens' (ST m) [Listener m]
- idcounter :: forall m. Lens' (ST m) Int
- coeval_ :: forall a b m. (Prog m () -> m) -> Prog m a -> Prog' b -> StateT (ST m) Er (Maybe a, Prog' b)
- coeval__ :: forall a b m. (Prog m () -> m) -> ProgramViewT (Inst m) (State (Seq Any)) a -> Prog' b -> StateT (ST m) Er (Maybe a, Prog' b)
- runTest_ :: (Eq a, Show a, m ~ Prog n) => String -> (Prog n () -> n) -> (m n -> (n -> m ()) -> tm a -> m (a, m ())) -> tm a -> Prog' (a, Prog' ()) -> IO ()
- (==?) :: (Eq a, Show a, MonadRegisterRun m, EffectM m ~ Prog (AsocT m)) => a -> a -> m ()
- (==>) :: (Eq a, Show a, MonadRegisterRun m, EffectM m ~ Prog (AsocT m)) => Ref m a -> a -> m ()
Documentation
class MonadRegister tm => MonadRegisterRun tm where Source
listen :: (MonadRegister m, EffectM m ~ Prog t, Show a) => Port a -> (a -> Modifier m ()) -> m () Source
tell_ :: MonadWriter [Either a b] m => b -> m () Source
fail' :: MonadWriter [Either (Either a b1) b] m => b1 -> m () Source
unfail :: MonadWriter [Either (Either a b1) b] m => a -> m () Source
forall a . Show a => Listener | |
|
listenerStatus :: forall m. Lens' (Listener m) RegionStatusChange Source
listenerId :: forall m. Lens' (Listener m) Id Source
ST | |
|
coeval_ :: forall a b m. (Prog m () -> m) -> Prog m a -> Prog' b -> StateT (ST m) Er (Maybe a, Prog' b) Source
coeval__ :: forall a b m. (Prog m () -> m) -> ProgramViewT (Inst m) (State (Seq Any)) a -> Prog' b -> StateT (ST m) Er (Maybe a, Prog' b) Source
runTest_ :: (Eq a, Show a, m ~ Prog n) => String -> (Prog n () -> n) -> (m n -> (n -> m ()) -> tm a -> m (a, m ())) -> tm a -> Prog' (a, Prog' ()) -> IO () Source