Safe Haskell | None |
---|---|
Language | GHC2021 |
Polysemy.Conc.Interpreter.Lock
Description
Lock interpreters, Internal
Synopsis
- interpretLockPermissive :: forall (r :: [Effect]) a. Sem (Lock ': r) a -> Sem r a
- interpretLockReentrantEntered :: forall (r :: EffectRow). Members '[Sync (), Resource, Race, Mask, Embed IO] r => ThreadId -> InterpreterFor Lock r
- interpretLockReentrant :: forall (r :: EffectRow). Members '[Resource, Race, Mask, Embed IO] r => InterpreterFor Lock r
Documentation
interpretLockPermissive :: forall (r :: [Effect]) a. Sem (Lock ': r) a -> Sem r a Source #
Interpret Lock
by executing all actions unconditionally.
interpretLockReentrantEntered :: forall (r :: EffectRow). Members '[Sync (), Resource, Race, Mask, Embed IO] r => ThreadId -> InterpreterFor Lock r Source #
Subinterpreter for interpretLockReentrant
that checks whether the current thread is equal to the lock-acquiring
thread to allow reentry into the lock.