Instant is
off
|
Search plugin
|
Manual
|
haskell.org
takeTMVar
+stm
Packages
stm
takeTMVar
:: TMVar a -> STM a
stm
Control.Concurrent.STM.TMVar
Return the contents of the
TMVar
. If the
TMVar
is currently empty, the transaction will
retry
. After a
takeTMVar
, the
TMVar
is left empty.
try
TakeTMVar
:: TMVar a -> STM (Maybe a)
stm
Control.Concurrent.STM.TMVar
A version of
takeTMVar
that does not
retry
. The
tryTakeTMVar
function returns
Nothing
if the
TMVar
was empty, or
Just
a if the
TMVar
was full with contents a. After
tryTakeTMVar
, the
TMVar
is left empty.
©
Neil Mitchell
2004-2012, version 4.2.11