Copyright | Copyright (c) 2009-2017 David Sorokin <david.sorokin@gmail.com> |
---|---|
License | BSD3 |
Maintainer | David Sorokin <david.sorokin@gmail.com> |
Stability | experimental |
Safe Haskell | None |
Language | Haskell2010 |
Tested with: GHC 8.0.1
The module defines helper functions for working with MVar
.
- withMVarComp :: (MonadComp m, MonadIO m, MonadMask m) => MVar a -> (a -> m b) -> m b
- withMVarParameter :: (MonadComp m, MonadIO m, MonadMask m) => MVar a -> (a -> Parameter m b) -> Parameter m b
- withMVarSimulation :: (MonadComp m, MonadIO m, MonadMask m) => MVar a -> (a -> Simulation m b) -> Simulation m b
- withMVarDynamics :: (MonadComp m, MonadIO m, MonadMask m) => MVar a -> (a -> Dynamics m b) -> Dynamics m b
- withMVarEvent :: (MonadComp m, MonadIO m, MonadMask m) => MVar a -> (a -> Event m b) -> Event m b
Documentation
withMVarComp :: (MonadComp m, MonadIO m, MonadMask m) => MVar a -> (a -> m b) -> m b Source #
Like withMVar
but operates within the specified computation.
withMVarParameter :: (MonadComp m, MonadIO m, MonadMask m) => MVar a -> (a -> Parameter m b) -> Parameter m b Source #
withMVarSimulation :: (MonadComp m, MonadIO m, MonadMask m) => MVar a -> (a -> Simulation m b) -> Simulation m b Source #
Like withMVar
but operates within the Simulation
computation.