From 616438fe9ab5e3ae7d73e9ad838e9b7bdea1ea59 Mon Sep 17 00:00:00 2001 From: Roberto Ierusalimschy Date: Mon, 31 May 2004 15:51:50 -0300 Subject: new way to use `vararg' parameters (with `...') --- lstate.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'lstate.h') diff --git a/lstate.h b/lstate.h index 3a1eb329..0ac69529 100644 --- a/lstate.h +++ b/lstate.h @@ -1,5 +1,5 @@ /* -** $Id: lstate.h,v 2.2 2004/03/23 17:02:58 roberto Exp roberto $ +** $Id: lstate.h,v 2.3 2004/05/14 19:25:09 roberto Exp roberto $ ** Global State ** See Copyright Notice in lua.h */ @@ -71,6 +71,7 @@ typedef struct stringtable { */ typedef struct CallInfo { StkId base; /* base for this function */ + StkId func; /* function index in the stack */ StkId top; /* top for this function */ int nresults; /* expected number of results from this function */ union { @@ -86,10 +87,10 @@ typedef struct CallInfo { -#define curr_func(L) (clvalue(L->base - 1)) -#define ci_func(ci) (clvalue((ci)->base - 1)) +#define curr_func(L) (clvalue(L->ci->func)) +#define ci_func(ci) (clvalue((ci)->func)) #define f_isLua(ci) (!ci_func(ci)->c.isC) -#define isLua(ci) (ttisfunction((ci)->base - 1) && f_isLua(ci)) +#define isLua(ci) (ttisfunction((ci)->func) && f_isLua(ci)) /* -- cgit v1.2.3-55-g6feb