diff options
| author | gingerBill <bill@gingerbill.org> | 2023-05-25 12:17:39 +0100 |
|---|---|---|
| committer | gingerBill <bill@gingerbill.org> | 2023-05-25 12:17:39 +0100 |
| commit | 2fda3cf9880cee1c9dfae4ac34b1c10aefbb5a8f (patch) | |
| tree | 267bd56eab86d661ff070a186b8dc0205c62a39a /core | |
| parent | 03b7194c97ee29e9883c135e75535fad1cda9071 (diff) | |
Remove os dependency in primitives_openbsd.odin
Diffstat (limited to 'core')
| -rw-r--r-- | core/sync/primitives_openbsd.odin | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/core/sync/primitives_openbsd.odin b/core/sync/primitives_openbsd.odin index 4072a14e8..ff3ff837f 100644 --- a/core/sync/primitives_openbsd.odin +++ b/core/sync/primitives_openbsd.odin @@ -2,8 +2,14 @@ //+private package sync -import "core:os" +foreign import libc "system:c" + +@(default_calling_convention="c") +foreign libc { + @(link_name="getthrid", private="file") + _unix_getthrid :: proc() -> int --- +} _current_thread_id :: proc "contextless" () -> int { - return os.current_thread_id() + return _unix_getthrid() } |