flix

0.78.0

ReadWriteLock

Functions on read-write locks.

Definitions

def mkLock(_: Region[r]): ReadWriteLock[r] \ r§ Source

Returns a fresh read-write lock in the given region.

def readLock(lock: ReadWriteLock[r]): Unit \ r§ Source

Acquires the read lock of lock, blocking until it is available.

def unlockRead(lock: ReadWriteLock[r]): Unit \ r§ Source

Releases the read lock of lock.

def unlockWrite(lock: ReadWriteLock[r]): Unit \ r§ Source

Releases the write lock of lock.

def writeLock(lock: ReadWriteLock[r]): Unit \ r§ Source

Acquires the write lock of lock, blocking until it is available.