aboutsummaryrefslogtreecommitdiff
path: root/src/lj_obj.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/lj_obj.h')
-rw-r--r--src/lj_obj.h7
1 files changed, 1 insertions, 6 deletions
diff --git a/src/lj_obj.h b/src/lj_obj.h
index d8aab90a..f243a75b 100644
--- a/src/lj_obj.h
+++ b/src/lj_obj.h
@@ -351,7 +351,6 @@ typedef struct GCproto {
351 MSize sizebc; /* Number of bytecode instructions. */ 351 MSize sizebc; /* Number of bytecode instructions. */
352 GCRef gclist; 352 GCRef gclist;
353 MRef k; /* Split constant array (points to the middle). */ 353 MRef k; /* Split constant array (points to the middle). */
354 MRef bc; /* Array of bytecode instructions. */
355 MRef uv; /* Upvalue list. local slot|0x8000 or parent uv idx. */ 354 MRef uv; /* Upvalue list. local slot|0x8000 or parent uv idx. */
356 MSize sizekgc; /* Number of collectable constants. */ 355 MSize sizekgc; /* Number of collectable constants. */
357 MSize sizekn; /* Number of lua_Number constants. */ 356 MSize sizekn; /* Number of lua_Number constants. */
@@ -381,11 +380,7 @@ typedef struct GCproto {
381 gcref(mref((pt)->k, GCRef)[(idx)])) 380 gcref(mref((pt)->k, GCRef)[(idx)]))
382#define proto_knum(pt, idx) \ 381#define proto_knum(pt, idx) \
383 check_exp((uintptr_t)(idx) < (pt)->sizekn, mref((pt)->k, lua_Number)[(idx)]) 382 check_exp((uintptr_t)(idx) < (pt)->sizekn, mref((pt)->k, lua_Number)[(idx)])
384#define proto_bc(pt) (mref((pt)->bc, BCIns)) 383#define proto_bc(pt) ((BCIns *)((char *)(pt) + sizeof(GCproto)))
385#define proto_ins(pt, pos) \
386 check_exp((uintptr_t)(pos) < (pt)->sizebc, proto_bc(pt)[(pos)])
387#define proto_insptr(pt, pos) \
388 check_exp((uintptr_t)(pos) < (pt)->sizebc, &proto_bc(pt)[(pos)])
389#define proto_bcpos(pt, pc) ((BCPos)((pc) - proto_bc(pt))) 384#define proto_bcpos(pt, pc) ((BCPos)((pc) - proto_bc(pt)))
390#define proto_uv(pt) (mref((pt)->uv, uint16_t)) 385#define proto_uv(pt) (mref((pt)->uv, uint16_t))
391 386