The Battle for Wesnoth  1.13.4+dev
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
Macros | Functions
lfunc.h File Reference
#include "lobject.h"
Include dependency graph for lfunc.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define sizeCclosure(n)
 
#define sizeLclosure(n)
 

Functions

LUAI_FUNC ProtoluaF_newproto (lua_State *L)
 
LUAI_FUNC ClosureluaF_newCclosure (lua_State *L, int nelems)
 
LUAI_FUNC ClosureluaF_newLclosure (lua_State *L, int nelems)
 
LUAI_FUNC UpValluaF_newupval (lua_State *L)
 
LUAI_FUNC UpValluaF_findupval (lua_State *L, StkId level)
 
LUAI_FUNC void luaF_close (lua_State *L, StkId level)
 
LUAI_FUNC void luaF_freeproto (lua_State *L, Proto *f)
 
LUAI_FUNC void luaF_freeupval (lua_State *L, UpVal *uv)
 
LUAI_FUNC const char * luaF_getlocalname (const Proto *func, int local_number, int pc)
 

Macro Definition Documentation

#define sizeCclosure (   n)
Value:
(cast(int, sizeof(CClosure)) + \
cast(int, sizeof(TValue)*((n)-1)))
#define cast(t, exp)
Definition: llimits.h:92
GLclampd n
Definition: glew.h:5903

Definition at line 13 of file lfunc.h.

Referenced by freeobj(), luaF_newCclosure(), and traverseCclosure().

#define sizeLclosure (   n)
Value:
(cast(int, sizeof(LClosure)) + \
cast(int, sizeof(TValue *)*((n)-1)))
#define cast(t, exp)
Definition: llimits.h:92
GLclampd n
Definition: glew.h:5903

Definition at line 16 of file lfunc.h.

Referenced by freeobj(), luaF_newLclosure(), and traverseLclosure().

Function Documentation

LUAI_FUNC void luaF_close ( lua_State L,
StkId  level 
)
LUAI_FUNC UpVal* luaF_findupval ( lua_State L,
StkId  level 
)
LUAI_FUNC void luaF_freeproto ( lua_State L,
Proto f 
)
LUAI_FUNC void luaF_freeupval ( lua_State L,
UpVal uv 
)

Definition at line 81 of file lfunc.cpp.

References luaM_free, UpVal::u, unlinkupval(), UpVal::v, and UpVal::value.

Referenced by freeobj(), and luaF_close().

LUAI_FUNC const char* luaF_getlocalname ( const Proto func,
int  local_number,
int  pc 
)

Definition at line 149 of file lfunc.cpp.

References getstr, i, Proto::locvars, Proto::sizelocvars, LocVar::startpc, and LocVar::varname.

Referenced by findlocal(), getobjname(), and lua_getlocal().

LUAI_FUNC Closure* luaF_newCclosure ( lua_State L,
int  nelems 
)

Definition at line 22 of file lfunc.cpp.

References Closure::c, c, cast_byte, GCObject::cl, LUA_TCCL, luaC_newobj(), and sizeCclosure.

Referenced by lua_pushcclosure().

LUAI_FUNC Closure* luaF_newLclosure ( lua_State L,
int  nelems 
)
LUAI_FUNC Proto* luaF_newproto ( lua_State L)
LUAI_FUNC UpVal* luaF_newupval ( lua_State L)

Definition at line 38 of file lfunc.cpp.

References LUA_TUPVAL, luaC_newobj(), setnilvalue, UpVal::u, GCObject::uv, UpVal::v, and UpVal::value.

Referenced by f_parser().