diff --git a/support/src/utils/unix.cpp b/support/src/utils/unix.cpp index 7d647690..5871db82 100644 --- a/support/src/utils/unix.cpp +++ b/support/src/utils/unix.cpp @@ -25,13 +25,15 @@ #include "utils/collection.hpp" namespace repertory::utils { -auto convert_to_uint64(pthread_t thread) -> std::uint64_t { #if defined(__APPLE__) +auto convert_to_uint64(pthread_t thread) -> std::uint64_t { return reinterpret_cast(thread); -#else // defined(__APPLE__) - return static_cast(thread); -#endif // defined(__APPLE__) } +#else // defined(__APPLE__) +auto convert_to_uint64(const pthread_t &thread) -> std::uint64_t { + return static_cast(thread); +} +#endif // defined(__APPLE__) auto get_last_error_code() -> int { return errno; }