Quantcast
Channel: WE MOVED to github.com/microsoft/cpprestsdk. This site is not monitored!
Viewing all articles
Browse latest Browse all 4845

New Post: GetCurrentThreadId

$
0
0
And on StackOverflow read comments.

As solution I think that reinterpret_cast<long>(reinterpret_cast<void*>(pthread_self())); a good choice,
but in STL we have type thread::id that have thread_id_t or something close to this.
Anyway thread::id type can be represented as hash (something like size_t or unsigned integer 32/64 bit).
Maybe we should use a unsigned integers? and moving to STL version?

Viewing all articles
Browse latest Browse all 4845

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>