lua-users home
lua-l archive

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


>> In 4.1, you have loadfile and loadbuffer leave precompiled stuff in the stack.
>> If you want the exact binary representation used by luac, use ldumplib.c in
>> src/luac.
>
>In what form does this leave the code on the stack? -- loadfile/buffer seems
>to leave a Closure* and the ldumplib is doing something odd with luaM_buffer
>or something.

loadfile/buffer leaves an ordinary Lua function representing the chunk loaded.
ldumplib creates a Lua string containig the binary representation of the chunk.

--lhf