Prevent new calls that won't work as expected

This commit is contained in:
2025-06-01 16:11:35 -07:00
parent 297e6e4996
commit 93b63a5831

View File

@@ -41,6 +41,7 @@ function mknew(tt)
local mt,oldinit,more = {__index=tt},tt.superinit,rawget(tt, "init")
tt.new=function(ret)
if(not ret) ret = {}
ret.new = false
setmetatable(ret, mt)
if(oldinit) oldinit(ret)
if (more) more(ret)