From f849078fb3c1725573db9b6fc8c0176808032350 Mon Sep 17 00:00:00 2001 From: hlaaf Date: Sat, 26 May 2018 12:11:22 +0300 Subject: [PATCH] Fix allocator calls --- Destructors.rest | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Destructors.rest b/Destructors.rest index 9994820..f961cfb 100644 --- a/Destructors.rest +++ b/Destructors.rest @@ -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