Small fixes to stdlib. (#1247)

Small fixes to stdlib. Match the signature of `NativeConditionVariable.wait_timeout` and `NativeMutex.lock_timeout` of thread_win32.c3 to `ConditionVariable.wait_timeout` and `TimedMutex.lock_timeout` to avoid casting errors. Add `time::us`.
This commit is contained in:
Christian Buttner
2024-07-20 19:19:16 +02:00
committed by GitHub
parent 480325177c
commit edc55a2afd
7 changed files with 19 additions and 10 deletions

View File

@@ -131,7 +131,8 @@ extern fn Win32_BOOL showWindow(Win32_HWND, CInt) @extern("ShowWindow");
extern fn Win32_BOOL translateMessage(Win32_MSG* lpMsg) @extern("TranslateMessage");
extern fn Win32_BOOL updateWindow(Win32_HWND) @extern("UpdateWindow");
macro getWindowLongPtr(Win32_HWND hWnd, CInt nIndex) {
macro getWindowLongPtr(Win32_HWND hWnd, CInt nIndex)
{
$if env::ARCH_64_BIT:
return getWindowLongPtrW(hWnd, nIndex);
$else
@@ -139,7 +140,8 @@ macro getWindowLongPtr(Win32_HWND hWnd, CInt nIndex) {
$endif
}
macro setWindowLongPtr(Win32_HWND hWnd, CInt nIndex, dwNewLong) {
macro setWindowLongPtr(Win32_HWND hWnd, CInt nIndex, dwNewLong)
{
$if env::ARCH_64_BIT:
return setWindowLongPtrW(hWnd, nIndex, dwNewLong);
$else