summaryrefslogtreecommitdiff
path: root/src/lj_obj.h
diff options
context:
space:
mode:
authorMike Pall <mike>2010-02-05 01:35:38 +0100
committerMike Pall <mike>2010-02-05 01:35:38 +0100
commita0914c409b615af85eafb7e2787be628483ffde2 (patch)
treecce46eed095637c4d4873ce38c4dbd952f7851d3 /src/lj_obj.h
parent8dcc4364cf2c56c9bdd8047fd0dceb4b70f727d2 (diff)
downloadluajit-a0914c409b615af85eafb7e2787be628483ffde2.tar.gz
luajit-a0914c409b615af85eafb7e2787be628483ffde2.tar.bz2
luajit-a0914c409b615af85eafb7e2787be628483ffde2.zip
32/64 bit memory ref cleanup, part 4: GCproto ->varinfo.
Diffstat (limited to 'src/lj_obj.h')
-rw-r--r--src/lj_obj.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/lj_obj.h b/src/lj_obj.h
index cdb90dff..a0dc689c 100644
--- a/src/lj_obj.h
+++ b/src/lj_obj.h
@@ -339,7 +339,7 @@ enum {
339#define round_nkgc(n) (((n) + SCALE_NUM_GCO-1) & ~(SCALE_NUM_GCO-1)) 339#define round_nkgc(n) (((n) + SCALE_NUM_GCO-1) & ~(SCALE_NUM_GCO-1))
340 340
341typedef struct VarInfo { 341typedef struct VarInfo {
342 GCstr *name; /* Local variable name. */ 342 GCRef name; /* Local variable name. */
343 BCPos startpc; /* First point where the local variable is active. */ 343 BCPos startpc; /* First point where the local variable is active. */
344 BCPos endpc; /* First point where the local variable is dead. */ 344 BCPos endpc; /* First point where the local variable is dead. */
345} VarInfo; 345} VarInfo;
@@ -365,7 +365,7 @@ typedef struct GCproto {
365 BCLine linedefined; /* First line of the function definition. */ 365 BCLine linedefined; /* First line of the function definition. */
366 BCLine lastlinedefined; /* Last line of the function definition. */ 366 BCLine lastlinedefined; /* Last line of the function definition. */
367 MRef lineinfo; /* Map from bytecode instructions to source lines. */ 367 MRef lineinfo; /* Map from bytecode instructions to source lines. */
368 struct VarInfo *varinfo; /* Names and extents of local variables. */ 368 MRef varinfo; /* Names and extents of local variables. */
369 MRef uvname; /* Array of upvalue names (GCRef of GCstr). */ 369 MRef uvname; /* Array of upvalue names (GCRef of GCstr). */
370 GCRef chunkname; /* Name of the chunk this function was defined in. */ 370 GCRef chunkname; /* Name of the chunk this function was defined in. */
371} GCproto; 371} GCproto;
@@ -396,6 +396,7 @@ typedef struct GCproto {
396#define proto_lineinfo(pt) (mref((pt)->lineinfo, BCLine)) 396#define proto_lineinfo(pt) (mref((pt)->lineinfo, BCLine))
397#define proto_line(pt, pos) \ 397#define proto_line(pt, pos) \
398 check_exp((uintptr_t)(pos) < (pt)->sizebc, proto_lineinfo(pt)[(pos)]) 398 check_exp((uintptr_t)(pos) < (pt)->sizebc, proto_lineinfo(pt)[(pos)])
399#define proto_varinfo(pt) (mref((pt)->varinfo, VarInfo))
399 400
400/* -- Upvalue object ------------------------------------------------------ */ 401/* -- Upvalue object ------------------------------------------------------ */
401 402