MCPcopy Create free account
hub / github.com/David-Haim/concurrencpp / ~async_lock

Method ~async_lock

source/threads/async_lock.cpp:37–42  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

35*/
36
37async_lock::~async_lock() noexcept {
38#ifdef CRCPP_DEBUG_MODE
39 std::unique_lock<std::mutex> lock(m_awaiter_lock);
40 assert(!m_locked && "async_lock is dstroyed while it's locked.");
41#endif
42}
43
44concurrencpp::lazy_result<scoped_async_lock> async_lock::lock_impl(std::shared_ptr<executor> resume_executor, bool with_raii_guard) {
45 auto resume_synchronously = true; // indicates if the locking coroutine managed to lock the lock on first attempt

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected