1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

sync: fix C.pthread_mutex_t struct typedef is missing in darwin (fix: #15491) (#15845)

This commit is contained in:
shove
2022-09-23 14:48:05 +08:00
committed by GitHub
parent 5c716afb39
commit 6ec931c781
2 changed files with 31 additions and 0 deletions

View File

@@ -30,6 +30,18 @@ fn C.pthread_cond_wait(voidptr, voidptr) int
fn C.pthread_cond_timedwait(voidptr, voidptr, voidptr) int
fn C.pthread_cond_destroy(voidptr) int
[typedef]
struct C.pthread_mutex_t {}
[typedef]
struct C.pthread_rwlock_t {}
[typedef]
struct C.pthread_rwlockattr_t {}
[typedef]
struct C.sem_t {}
// [init_with=new_mutex] // TODO: implement support for this struct attribute, and disallow Mutex{} from outside the sync.new_mutex() function.
[heap]
pub struct Mutex {