cgen: remove srwlock definition workaround for tcc on windows (#8652)

pull/8704/head
spaceface 2021-02-09 11:44:18 +01:00 committed by GitHub
parent 4152c704f3
commit 1bb4be17d8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 8 deletions

View File

@ -5,6 +5,8 @@ module sync
import time
#include <synchapi.h>
fn C.InitializeConditionVariable(voidptr)
fn C.WakeConditionVariable(voidptr)
fn C.SleepConditionVariableSRW(voidptr, voidptr, u32, u32) int

View File

@ -280,14 +280,6 @@ $c_common_macros
#pragma comment(lib, "Dbghelp")
extern wchar_t **_wenviron;
#elif !defined(SRWLOCK_INIT)
// these seem to be missing on Windows tcc
typedef struct SRWLOCK { void* SRWLOCK; } SRWLOCK;
void InitializeSRWLock(void*);
void AcquireSRWLockShared(void*);
void AcquireSRWLockExclusive(void*);
void ReleaseSRWLockShared(void*);
void ReleaseSRWLockExclusive(void*);
#endif
#else
#include <pthread.h>