diff options
Diffstat (limited to 'lundump.h')
-rw-r--r-- | lundump.h | 15 |
1 files changed, 15 insertions, 0 deletions
@@ -7,6 +7,8 @@ | |||
7 | #ifndef lundump_h | 7 | #ifndef lundump_h |
8 | #define lundump_h | 8 | #define lundump_h |
9 | 9 | ||
10 | #include <limits.h> | ||
11 | |||
10 | #include "llimits.h" | 12 | #include "llimits.h" |
11 | #include "lobject.h" | 13 | #include "lobject.h" |
12 | #include "lzio.h" | 14 | #include "lzio.h" |
@@ -25,6 +27,19 @@ | |||
25 | 27 | ||
26 | #define LUAC_FORMAT 0 /* this is the official format */ | 28 | #define LUAC_FORMAT 0 /* this is the official format */ |
27 | 29 | ||
30 | |||
31 | /* | ||
32 | ** Type to handle MSB Varint encoding: Try to get the largest unsigned | ||
33 | ** integer available. (It was enough to be the largest between size_t and | ||
34 | ** lua_Integer, but the C89 preprocessor knows nothing about size_t.) | ||
35 | */ | ||
36 | #if !defined(LUA_USE_C89) && defined(LLONG_MAX) | ||
37 | typedef unsigned long long varint_t; | ||
38 | #else | ||
39 | typedef unsigned long varint_t; | ||
40 | #endif | ||
41 | |||
42 | |||
28 | /* load one chunk; from lundump.c */ | 43 | /* load one chunk; from lundump.c */ |
29 | LUAI_FUNC LClosure* luaU_undump (lua_State* L, ZIO* Z, const char* name, | 44 | LUAI_FUNC LClosure* luaU_undump (lua_State* L, ZIO* Z, const char* name, |
30 | int fixed); | 45 | int fixed); |