Continue documenting public surface (#25)

Signed-off-by: Danny Canter <danny_canter@apple.com>
This commit is contained in:
Danny Canter
2025-06-06 10:34:19 -04:00
committed by GitHub
parent 46260fd6a6
commit fc4a124173
32 changed files with 215 additions and 33 deletions
@@ -31,6 +31,7 @@ public actor AsyncLock {
public init() {}
/// withLock provides a scoped locking API to run a function while holding the lock.
public func withLock<T: Sendable>(_ body: @Sendable @escaping (Context) async throws -> T) async rethrows -> T {
while self.busy {
await withCheckedContinuation { cc in