Implement OSSetCurrentThreadName on macOS

This commit is contained in:
PJB3005
2026-04-01 14:37:24 +02:00
parent 3cf2b25733
commit a005ce31b7
+4
View File
@@ -22,6 +22,8 @@
#if _WIN32
#define WIN32_LEAN_AND_MEAN 1
#include <windows.h>
#elif __APPLE__
#include <pthread.h>
#endif
// ============================================================================
@@ -722,6 +724,8 @@ void OSSetCurrentThreadName(const char* name) {
if (!SUCCEEDED(result)) {
CRASH("OSSetThreadName: SetThreadDescription failed");
}
#elif __APPLE__
pthread_setname_np(name);
#endif
}