diff options
author | Alon Zakai <alonzakai@gmail.com> | 2013-04-29 13:53:27 -0700 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2013-04-29 13:53:27 -0700 |
commit | aa62072c9b7dcc3b650af9fe24f23853c688d07b (patch) | |
tree | 0e7ec6479d598cf63cc4ac36cd6e6dc99dc190d3 /tests/lua/src/lundump.h | |
parent | 3b6735c64c450e50ec948c07bf9ddbe4a68a87dc (diff) |
make lua test build from source
Diffstat (limited to 'tests/lua/src/lundump.h')
-rw-r--r-- | tests/lua/src/lundump.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/tests/lua/src/lundump.h b/tests/lua/src/lundump.h new file mode 100644 index 00000000..2b8accec --- /dev/null +++ b/tests/lua/src/lundump.h @@ -0,0 +1,28 @@ +/* +** $Id: lundump.h,v 1.39 2012/05/08 13:53:33 roberto Exp $ +** load precompiled Lua chunks +** See Copyright Notice in lua.h +*/ + +#ifndef lundump_h +#define lundump_h + +#include "lobject.h" +#include "lzio.h" + +/* load one chunk; from lundump.c */ +LUAI_FUNC Closure* luaU_undump (lua_State* L, ZIO* Z, Mbuffer* buff, const char* name); + +/* make header; from lundump.c */ +LUAI_FUNC void luaU_header (lu_byte* h); + +/* dump one chunk; from ldump.c */ +LUAI_FUNC int luaU_dump (lua_State* L, const Proto* f, lua_Writer w, void* data, int strip); + +/* data to catch conversion errors */ +#define LUAC_TAIL "\x19\x93\r\n\x1a\n" + +/* size in bytes of header of binary files */ +#define LUAC_HEADERSIZE (sizeof(LUA_SIGNATURE)-sizeof(char)+2+6+sizeof(LUAC_TAIL)-sizeof(char)) + +#endif |