Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: add countdown latch example to
Semaphore
## Motivation Some users have requested that `tokio::sync` add a countdown latch synchronization primitive. This can be implemented using the existing `Semaphore` API, so rather than adding a countdown latch type, we should add documentation examples showing how the `Semaphore` can be used as a countdown latch. ## Solution This branch adds an example to the `tokio::sync::Semaphore` docs demonstrating its usage as a countdown latch. This example was extracted from #6087 (comment). Closes #6087
- Loading branch information