diff options
Diffstat (limited to 'lib/core')
-rw-r--r-- | lib/core/locks.nim | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/core/locks.nim b/lib/core/locks.nim index d6d579ba0..0143957ce 100644 --- a/lib/core/locks.nim +++ b/lib/core/locks.nim @@ -60,11 +60,11 @@ template withLock*(a: Lock, body: untyped) = ## Acquires the given lock, executes the statements in body and ## releases the lock after the statements finish executing. mixin acquire, release - a.acquire() + acquire(a) {.locks: [a].}: try: body finally: - a.release() + release(a) {.pop.} |