Bordeaux-Threads

Version 0.8.8

Common Lisp threading library

Function ACQUIRE-RECURSIVE-LOCK, RELEASE-RECURSIVE-LOCK

Syntax:

acquire-recursive-lock lock &key (wait t) timeout => generalized-boolean
release-recursive-lock lock => lock

Arguments and values:

lock -> a recursive-lock object.
wait -> a generalized boolean.
timeout -> a non-negative real number.
generalized-boolean -> a generalized boolean.

Description:

Acquire lock for the calling thread.

wait governs what happens if the lock is not available: if wait is true, the calling thread will wait until the lock is available and then acquire it; if wait is nil, acquire-recursive-lock will return immediately. If wait is true, timeout may specify a maximum amount of seconds to wait for the lock to become available.

acquire-recursive-lock returns true if the lock was acquired, otherwise false.

Exceptional situations:

Signals an error of type type-error if lock is not a recursive-lock object.
Signals an error of type type-error if timeout is neither nil nor a non-negative real number.

See also:

recursive-lock

Notes:

None.

Last updated on 2022-01-07
Published on 2022-01-07
Edit on GitHub