summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichal Terepeta <michal.terepeta@gmail.com>2021-10-24 15:40:52 +0200
committerAndrew Gallant <jamslam@gmail.com>2023-07-08 18:52:42 -0400
commitcb7501ff111d32f636138cfc8975289fc5001f50 (patch)
tree5c3c7fcd512c247578275fb8bcbfae62c31f49fc
parent3b66f37a31d4fcc2aedc0737692c820d26452be4 (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.rs2
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);
}