lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


To quote the 5.2 manual:

When ptr is NULL, osize encodes the kind of object that Lua is allocating.

On Sun, Mar 9, 2014 at 1:45 AM, Rena <hyperhacker@gmail.com> wrote:
> I just put together a simple test allocator in Lua:
> http://pastie.org/8899878
>
> The very first allocation Lua makes is a realloc, resizing a block from 8
> bytes to 704.
>
> I don't understand what this means... how can be be realloc()ing a block it
> never allocated?
>
> --
> Sent from my Game Boy.