This module contains Nim's support for locks and condition vars.
Procs
proc initLock(lock: var Lock) {...}{.inline, raises: [], tags: [].}
- Initializes the given lock. Source Edit
proc deinitLock(lock: var Lock) {...}{.inline, raises: [], tags: [].}
- Frees the resources associated with the lock. Source Edit
proc tryAcquire(lock: var Lock): bool {...}{.raises: [], tags: [].}
- Tries to acquire the given lock. Returns true on success. Source Edit
proc acquire(lock: var Lock) {...}{.raises: [], tags: [].}
- Acquires the given lock. Source Edit
proc release(lock: var Lock) {...}{.raises: [], tags: [].}
- Releases the given lock. Source Edit
proc initCond(cond: var Cond) {...}{.inline, raises: [], tags: [].}
- Initializes the given condition variable. Source Edit
proc deinitCond(cond: var Cond) {...}{.inline, raises: [], tags: [].}
- Frees the resources associated with the condition variable. Source Edit
proc wait(cond: var Cond; lock: var Lock) {...}{.inline, raises: [], tags: [].}
- waits on the condition variable cond. Source Edit
proc signal(cond: var Cond) {...}{.inline, raises: [], tags: [].}
- sends a signal to the condition variable cond. Source Edit