8#include "Misc/AssertionMacros.h"
13
14
15
24 int Err = pthread_rwlock_init(&Mutex,
nullptr);
25 checkf(Err == 0, TEXT(
"pthread_rwlock_init failed with error: %d"), Err);
30 int Err = pthread_rwlock_destroy(&Mutex);
31 checkf(Err == 0, TEXT(
"pthread_rwlock_destroy failed with error: %d"), Err);
36 int Err = pthread_rwlock_rdlock(&Mutex);
37 checkf(Err == 0, TEXT(
"pthread_rwlock_rdlock failed with error: %d"), Err);
42 int Err = pthread_rwlock_wrlock(&Mutex);
43 checkf(Err == 0, TEXT(
"pthread_rwlock_wrlock failed with error: %d"), Err);
48 int Err = pthread_rwlock_tryrdlock(&Mutex);
54 int Err = pthread_rwlock_trywrlock(&Mutex);
60 int Err = pthread_rwlock_unlock(&Mutex);
61 checkf(Err == 0, TEXT(
"pthread_rwlock_unlock failed with error: %d"), Err);
66 int Err = pthread_rwlock_unlock(&Mutex);
67 checkf(Err == 0, TEXT(
"pthread_rwlock_unlock failed with error: %d"), Err);
#define checkf(expr, format,...)
FPThreadsRWLock(const FPThreadsRWLock &)=delete
FPThreadsRWLock & operator=(const FPThreadsRWLock &)=delete