* @brief Get a pointer to the thread pool that owns the current thread. If this thread belongs to a `BS::thread_pool` object, the return value will be a `void` pointer to that object. Otherwise, for example if this thread is the main thread or an independent thread not in any pools, `std::nullopt` will be returned. * * @return An `std::optional` object, optionally containing a pointer to
| 985 | * @return An `std::optional` object, optionally containing a pointer to a thread pool. Note that this will be a `void` pointer, so it must be cast to the desired instantiation of the `BS::thread_pool` template in order to use any member functions. |
| 986 | */ |
| 987 | [[nodiscard]] static std::optional<void*> get_pool() noexcept |
| 988 | { |
| 989 | return my_pool; |
| 990 | } |
| 991 | |
| 992 | #ifdef BS_THREAD_POOL_NATIVE_EXTENSIONS |
| 993 | /** |
nothing calls this directly
no outgoing calls
no test coverage detected