Is there a way to get any kind of thread identifier of the currently running thread without resorting to Objective-C\'s NSThread.
I\'m improving our custom debug tracing
See pthread_getname_np
.
Unfortunately NSThread's name is not currently pushed down to that. The NSThread name is just an ivar, so there will be no way to get at it except through the method. You could always make a C function that makes the autorelease pool and gets the name. Your C++ code then doesn't have to be compiled as ObjC++.
pthread_getname_np
is probably a bit more useful than NSThread's name right now anyway. gdb and Instruments don't know about NSThread's name, only the pthread level name.