MCPcopy Create free account
hub / github.com/chen3feng/toft / AnyTaskPending

Method AnyTaskPending

system/threading/thread_pool.cpp:158–166  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

156}
157
158bool ThreadPool::AnyTaskPending() const {
159 for (size_t i = 0; i < m_num_threads; ++i) {
160 MutexLocker locker(&m_thread_contexts[i].mutex);
161 if (!m_thread_contexts[i].pending_tasks.empty())
162 return true;
163 }
164
165 return false;
166}
167
168bool ThreadPool::AnyThreadRunning() const {
169 for (size_t i = 0; i < m_num_threads; ++i) {

Callers

nothing calls this directly

Calls 1

emptyMethod · 0.45

Tested by

no test coverage detected