package picos_std
Module Semaphore.CountingSource
A counting semaphore.
Represents a counting semaphore.
make initial creates a new counting semaphore with the given initial count.
release semaphore increments the count of the semaphore.
ℹ️ This operation is not cancelable.
acquire semaphore waits until the count of the semaphore is greater than 0 and then atomically decrements the count.
try_acquire semaphore attempts to atomically decrement the count of the semaphore unless the count is already 0.