require explicit cleanup

This commit is contained in:
Sky Johnson 2025-05-22 11:11:16 -05:00
parent 7a9dfd47d3
commit 3817f80dc4

View File

@ -71,7 +71,6 @@ func New(openLibs ...bool) *State {
// Close closes the Lua state and frees resources
func (s *State) Close() {
if s.L != nil {
s.Cleanup() // Clean up Go function registry
C.lua_close(s.L)
s.L = nil
}