withReadLock

suspend fun <T> withReadLock(block: suspend () -> T): T(source)

Run the given block of code while holding the read lock. Multiple coroutines may run their read blocks concurrently. See the class-level KDoc for reentrancy and cancellation warnings.