Fix allocator calls
This commit is contained in:
parent
7e9e01f365
commit
f849078fb3
|
@ -210,15 +210,15 @@ The current design for an allocator looks like this:
|
|||
|
||||
proc alloc*(size: int): pointer =
|
||||
let a = getCurrentAllocator()
|
||||
result = a.alloc(a, size)
|
||||
result = a.alloc(p, size)
|
||||
|
||||
proc dealloc*(p: pointer; size: int) =
|
||||
let a = getCurrentAllocator()
|
||||
a.dealloc(a, size)
|
||||
a.dealloc(p, size)
|
||||
|
||||
proc realloc*(p: pointer; oldSize, newSize: int): pointer =
|
||||
let a = getCurrentAllocator()
|
||||
result = a.realloc(a, oldSize, newSize)
|
||||
result = a.realloc(p, oldSize, newSize)
|
||||
|
||||
|
||||
Pluggable GC
|
||||
|
|
Loading…
Reference in New Issue