1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-11-18 07:04:07 +01:00
Files
audacity/lib-src/ThreadPool/README.md
Edgar 04609bba01 Allow building Tenacity without Conan
Conan can still be used, but it is fully optional. This should help packagers
a lot.

Signed-off-by: Edgar <Edgar@AnotherFoxGuy.com>
2021-07-30 23:22:48 +00:00

319 B

ThreadPool

A simple C++11 Thread Pool implementation.

Basic usage:

// create thread pool with 4 worker threads
ThreadPool pool(4);

// enqueue and store future
auto result = pool.enqueue([](int answer) { return answer; }, 42);

// get result from future
std::cout << result.get() << std::endl;