record Lock : (Type -> Type) -> TypeA lock: a function that runs an action while holding mutual exclusion, for
any result type. `Synchronized.newLock` allocates one.
.withLock : Lock m -> m a -> m a.withLock : Lock m -> m a -> m awithLock : Lock m -> m a -> m ainterface Synchronized : (Type -> Type) -> TypeA monad whose actions can run under mutual exclusion. Sequential `IO` runs
can't race, so its lock is a no-op; a concurrent driver provides a real lock.
Synchronized IOnewLock : Synchronized m => IO (Lock m)