]> git.hungrycats.org Git - bees/commitdiff
task: fix try_lock argument description
authorZygo Blaxell <bees@furryterror.org>
Tue, 19 Nov 2024 20:29:41 +0000 (15:29 -0500)
committerZygo Blaxell <bees@furryterror.org>
Sun, 1 Dec 2024 04:30:33 +0000 (23:30 -0500)
try_lock allows specification of a different Task to be run instead of
the current Task when the lock is busy.

Signed-off-by: Zygo Blaxell <bees@furryterror.org>
include/crucible/task.h

index 8c9b3211c0d7144d5ac01505f132de4fee26672e..64add93283fa5617d0c115ed18d80be55d9029cc 100644 (file)
@@ -163,9 +163,9 @@ namespace crucible {
                /// (it is the ExclusionLock that owns the lock, so it can
                /// be passed to other Tasks or threads, but this is not
                /// recommended practice).
-               /// If not successful, current Task is appended to the
+               /// If not successful, the argument Task is appended to the
                /// task that currently holds the lock.  Current task is
-               /// expected to release any other ExclusionLock
+               /// expected to immediately release any other ExclusionLock
                /// objects it holds, and exit its Task function.
                ExclusionLock try_lock(const Task &task);