diff options
Diffstat (limited to 'lstate.h')
-rw-r--r-- | lstate.h | 16 |
1 files changed, 13 insertions, 3 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lstate.h,v 1.15 1999/02/25 15:17:01 roberto Exp roberto $ | 2 | ** $Id: lstate.h,v 1.16 1999/04/13 19:30:51 roberto Exp roberto $ |
3 | ** Global State | 3 | ** Global State |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -21,6 +21,16 @@ | |||
21 | 21 | ||
22 | typedef int StkId; /* index to stack elements */ | 22 | typedef int StkId; /* index to stack elements */ |
23 | 23 | ||
24 | |||
25 | /* | ||
26 | ** "jmp_buf" may be an array, so it is better to make sure it has an | ||
27 | ** address (and not that it *is* an address...) | ||
28 | */ | ||
29 | struct lua_longjmp { | ||
30 | jmp_buf b; | ||
31 | }; | ||
32 | |||
33 | |||
24 | struct Stack { | 34 | struct Stack { |
25 | TObject *top; | 35 | TObject *top; |
26 | TObject *stack; | 36 | TObject *stack; |
@@ -35,7 +45,7 @@ struct C_Lua_Stack { | |||
35 | }; | 45 | }; |
36 | 46 | ||
37 | 47 | ||
38 | typedef struct { | 48 | typedef struct stringtable { |
39 | int size; | 49 | int size; |
40 | int nuse; /* number of elements (including EMPTYs) */ | 50 | int nuse; /* number of elements (including EMPTYs) */ |
41 | TaggedString **hash; | 51 | TaggedString **hash; |
@@ -54,7 +64,7 @@ struct lua_State { | |||
54 | /* thread-specific state */ | 64 | /* thread-specific state */ |
55 | struct Stack stack; /* Lua stack */ | 65 | struct Stack stack; /* Lua stack */ |
56 | struct C_Lua_Stack Cstack; /* C2lua struct */ | 66 | struct C_Lua_Stack Cstack; /* C2lua struct */ |
57 | jmp_buf *errorJmp; /* current error recover point */ | 67 | struct lua_longjmp *errorJmp; /* current error recover point */ |
58 | char *Mbuffer; /* global buffer */ | 68 | char *Mbuffer; /* global buffer */ |
59 | int Mbuffbase; /* current first position of Mbuffer */ | 69 | int Mbuffbase; /* current first position of Mbuffer */ |
60 | int Mbuffsize; /* size of Mbuffer */ | 70 | int Mbuffsize; /* size of Mbuffer */ |