#ifndef INCLUDE_UTIL_PLATFORM_OS_UNIX_THREADID_HPP #define INCLUDE_UTIL_PLATFORM_OS_UNIX_THREADID_HPP #include #ifdef BOOST_HAS_PTHREADS #include #endif namespace Platform { namespace OS { #ifdef BOOST_HAS_PTHREADS #ifdef __CYGWIN__ inline int GetCurrentThreadId() { return reinterpret_cast(static_cast(pthread_self())); } #else inline int GetCurrentThreadId() { return static_cast(pthread_self()); } #endif #else inline int GetCurrentThreadId() { return 0; } #endif } } #endif // ! INCLUDE_UTIL_PLATFORM_OS_UNIX_THREADID_HPP