mirror of
https://github.com/logos-storage/nim-leopard.git
synced 2026-01-02 13:43:08 +00:00
fix windows build
This commit is contained in:
parent
6821b5fa6f
commit
05e62a3e4c
@ -22,13 +22,13 @@ let
|
||||
LeoAlignBytes* = if hasAvx2(): 32'u else: 16'u
|
||||
|
||||
when defined(windows):
|
||||
proc alignedAlloc(alignment, size: csize_t): pointer =
|
||||
alignedAllocWindows(size, alignment)
|
||||
|
||||
proc alignedAllocWindows(size, alignment: csize_t): pointer
|
||||
{.importc: "_aligned_malloc", header: "<malloc.h>".}
|
||||
# Beware of the arg order!
|
||||
|
||||
proc alignedAlloc(alignment, size: csize_t): pointer =
|
||||
alignedAllocWindows(size, alignment)
|
||||
|
||||
proc alignedFree*[T](p: ptr T)
|
||||
{.importc: "_aligned_free", header: "<malloc.h>".}
|
||||
elif defined(osx):
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user