Lua 5.1 Reference Manual - The Programming Language Lua
lua_close [-0, +0, -] void lua_close (lua_State *L); Destroys all objects in the given Lua state (calling the corresponding garbage-collection metamethods, if any) and frees all dynamic memory used by this state. On several platforms, you may not need to ...