blob: 2d7cbf18d6bd12f3153bdd8e6b615fe9b6fbf269 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
//+build freebsd
//+private
package sync
import "core:c"
foreign import dl "system:dl"
foreign dl {
pthread_getthreadid_np :: proc "c" () -> c.int ---
}
_current_thread_id :: proc "contextless" () -> int {
return int(pthread_getthreadid_np())
}
|