mirror of
https://github.com/lua/lua.git
synced 2024-12-12 19:43:26 +08:00
free prototype in (more or less) the same order it is created by
`undump'
This commit is contained in:
parent
6505503b49
commit
425e5813b0
6
lfunc.c
6
lfunc.c
@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
** $Id: lfunc.c,v 1.59 2002/08/30 19:09:21 roberto Exp roberto $
|
** $Id: lfunc.c,v 1.60 2002/10/16 20:40:58 roberto Exp roberto $
|
||||||
** Auxiliary functions to manipulate prototypes and closures
|
** Auxiliary functions to manipulate prototypes and closures
|
||||||
** See Copyright Notice in lua.h
|
** See Copyright Notice in lua.h
|
||||||
*/
|
*/
|
||||||
@ -96,10 +96,10 @@ Proto *luaF_newproto (lua_State *L) {
|
|||||||
|
|
||||||
void luaF_freeproto (lua_State *L, Proto *f) {
|
void luaF_freeproto (lua_State *L, Proto *f) {
|
||||||
luaM_freearray(L, f->code, f->sizecode, Instruction);
|
luaM_freearray(L, f->code, f->sizecode, Instruction);
|
||||||
|
luaM_freearray(L, f->p, f->sizep, Proto *);
|
||||||
|
luaM_freearray(L, f->k, f->sizek, TObject);
|
||||||
luaM_freearray(L, f->lineinfo, f->sizelineinfo, int);
|
luaM_freearray(L, f->lineinfo, f->sizelineinfo, int);
|
||||||
luaM_freearray(L, f->locvars, f->sizelocvars, struct LocVar);
|
luaM_freearray(L, f->locvars, f->sizelocvars, struct LocVar);
|
||||||
luaM_freearray(L, f->k, f->sizek, TObject);
|
|
||||||
luaM_freearray(L, f->p, f->sizep, Proto *);
|
|
||||||
luaM_freelem(L, f);
|
luaM_freelem(L, f);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user