Note: this function is deprecated, please use mask instead.
Applying block to a computation will execute that computation with asynchronous exceptions blocked. That is, any thread which attempts to raise an exception in the current thread with Control.Exception.throwTo will be blocked until asynchronous exceptions are unblocked again. There's no need to worry about re-enabling asynchronous exceptions; that is done automatically on exiting the scope of block.
Threads created by Control.Concurrent.forkIO inherit the blocked state from the parent; that is, to start a thread in blocked mode, use block $ forkIO .... This is particularly useful if you need to establish an exception handler in the forked thread before any asynchronous exceptions are received.
block-buffering should be enabled if possible. The size of the buffer is n items if the argument is Just n and is otherwise implementation-dependent.
returns True if asynchronous exceptions are blocked in the current thread.
The current thread was waiting to retry an atomic memory transaction that could never become possible to complete because there are no other threads referring to any of the TVars involved.
The thread is blocked on an MVar, but there are no other references to the MVar so it can't ever continue.
The thread is waiting to retry an STM transaction, but there are no other references to any TVars involved, so it can't ever continue.
The current thread was executing a call to Control.Concurrent.MVar.takeMVar that could never return, because there are no other references to this MVar.
blocked on a computation in progress by another thread
currently in a foreign call
blocked on some other resource. Without -threaded, I/O and threadDelay show up as BlockedOnOther, with -threaded they show up as BlockedOnMVar.
blocked in retry in an STM transaction
A variable type (BVar), monad (BTM), and arrow (BTA), which provide fast, atomic, composable, blocking inter-thread communication. Blocking transactions are strictly less expressive than software transactional memory, but may be more efficient under very high contention.
Block-oriented I/O Driver
Show more results