This commit is contained in:
Timothee Cour
2018-12-03 12:46:32 -08:00
parent b93fbcf09a
commit e7ab4817e2

View File

@@ -161,7 +161,8 @@ proc processID*(p: Process): int {.rtl, extern: "nosp$1".} =
proc processID*(): int =
## return current process ID
when defined(windows):
proc GetCurrentProcessId(): int32 {.stdcall, dynlib: "kernel32",
type DWORD = uint32
proc GetCurrentProcessId(): DWORD {.stdcall, dynlib: "kernel32",
importc: "GetCurrentProcessId".}
result = GetCurrentProcessId()
else: