|
Data.IORef | Portability | portable | Stability | experimental | Maintainer | libraries@haskell.org |
|
|
|
|
|
Description |
Mutable references in the IO monad.
|
|
Synopsis |
|
|
|
|
IORefs
|
|
|
A mutable variable in the IO monad
| Instances | |
|
|
|
Build a new IORef
|
|
|
Read the value of an IORef
|
|
|
Write a new value into an IORef
|
|
|
Mutate the contents of an IORef
|
|
|
Atomically modifies the contents of an IORef.
This function is useful for using IORef in a safe way in a multithreaded
program. If you only have one IORef, then using atomicModifyIORef to
access and modify it will prevent race conditions.
Extending the atomicity to multiple IORefs is problematic, so it
is recommended that if you need to do anything more complicated
then using MVar instead is a good idea.
|
|
|
Make a Weak pointer to an IORef
|
|
Produced by Haddock version 0.8 |