From c403e456b66ddacf7f8f974323e9cffdfe6365d4 Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Fri, 28 Jun 2024 11:18:14 -0300 Subject: New instruction format for SETLIST/NEWTABLE New instruction format 'ivABC' (a variant of iABC where parameter vC has 10 bits) allows constructors of up to 1024 elements to be coded without EXTRAARG. --- lcode.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'lcode.h') diff --git a/lcode.h b/lcode.h index 5b8eb29e..c1f16da0 100644 --- a/lcode.h +++ b/lcode.h @@ -61,8 +61,10 @@ typedef enum UnOpr { OPR_MINUS, OPR_BNOT, OPR_NOT, OPR_LEN, OPR_NOUNOPR } UnOpr; LUAI_FUNC int luaK_code (FuncState *fs, Instruction i); LUAI_FUNC int luaK_codeABx (FuncState *fs, OpCode o, int A, unsigned Bx); -LUAI_FUNC int luaK_codeABCk (FuncState *fs, OpCode o, int A, - int B, int C, int k); +LUAI_FUNC int luaK_codeABCk (FuncState *fs, OpCode o, int A, int B, int C, + int k); +LUAI_FUNC int luaK_codevABCk (FuncState *fs, OpCode o, int A, int B, int C, + int k); LUAI_FUNC int luaK_exp2const (FuncState *fs, const expdesc *e, TValue *v); LUAI_FUNC void luaK_fixline (FuncState *fs, int line); LUAI_FUNC void luaK_nil (FuncState *fs, int from, int n); -- cgit v1.2.3-55-g6feb