folly::coro::co_transition_lock

Async version of the folly::transition_lock TODO: add more transition policies beyond just from upgrade to exclusive

Synopsis

Declared in <folly/coro/SharedLock.h>

template<typename Mutex>
folly::coro::Task<std::unique_lock<Mutex>>
co_transition_lock(UpgradeLock<Mutex>& lock);

Return Value

A Task yielding a std::unique_lock holding the mutex.

Parameters

NameDescription
lockThe upgrade lock to transition to an exclusive lock.