| 1937 | */ |
| 1938 | template <typename F, typename R = std::invoke_result_t<std::decay_t<F>>> |
| 1939 | [[nodiscard]] std::future<R> submit_task(F&& task, const priority_t priority = 0) |
| 1940 | { |
| 1941 | task_and_future<R> ft(std::forward<F>(task)); |
| 1942 | detach_task(std::move(ft.task), priority); |
| 1943 | return std::move(ft.future); |
| 1944 | } |
| 1945 | |
| 1946 | /** |
| 1947 | * @brief Unpause the pool. The workers will resume retrieving new tasks out of the queue. Only enabled if the flag `BS::tp::pause` is enabled in the template parameter. |
nothing calls this directly
no test coverage detected