progschj / ThreadPool

A simple C++11 Thread Pool implementation
zlib License
7.64k stars 2.21k forks source link

How to get the thread id in 'task' function? #49

Open shixuansun opened 6 years ago

shixuansun commented 6 years ago

Hi, Thanks for your powerful thread pool. However, when I use it, I would like to get the logic thread id (0, 1, 2, 3) when I invoke the task function. I am wondering how to enable this function in current implementation? Look forward to your reply.