diff options
author | Michal Terepeta <michal.terepeta@gmail.com> | 2021-10-24 15:40:52 +0200 |
---|---|---|
committer | Andrew Gallant <jamslam@gmail.com> | 2023-07-08 18:52:42 -0400 |
commit | cb7501ff111d32f636138cfc8975289fc5001f50 (patch) | |
tree | 5c3c7fcd512c247578275fb8bcbfae62c31f49fc | |
parent | 3b66f37a31d4fcc2aedc0737692c820d26452be4 (diff) |
doc: clarify the comment on `Worker.work_done`
We call `work_done` only once the work has been actually performed
(otherwise `num_pending` could go to 0 before the actual work is done).
Closes #2039
-rw-r--r-- | crates/ignore/src/walk.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ignore/src/walk.rs b/crates/ignore/src/walk.rs index 602faaec..1f7d06e5 100644 --- a/crates/ignore/src/walk.rs +++ b/crates/ignore/src/walk.rs @@ -1681,7 +1681,7 @@ impl<'s> Worker<'s> { stack.pop() } - /// Signal that work has been received. + /// Signal that work has been finished. fn work_done(&self) { self.num_pending.fetch_sub(1, Ordering::SeqCst); } |