Scieneer Common Lisp 1.3.9 online documentation

thread:with-write-lock-held (lock &optional whostate &key :wait) &body body[Macro]

Execute the body with the thread:read-write-lock class lock held exclusively for writing, returning the results of the body upon success. If the lock is already held for either reading or writing then by default wait until it is released, otherwise if the wait key is nil then immediately return nil without processing the body.