internal static void *Malloc(long size) { var result = new PinnedArray <byte>(size); _pointers[(long)result.Ptr] = result; return(result.Ptr); }
internal static void MemMove(void *a, void *b, long size) { using (var temp = new PinnedArray <byte>(size)) { CRuntime.memcpy(temp.Ptr, b, size); CRuntime.memcpy(a, temp.Ptr, size); } }