lua 的语法糖

tb = {}
function tb:fun1()
    self  ---tb
end

function tb.fun2()
    self ---->无
end

tb:fun1()

tb.fun2()


------self 相当于 this

 lua函有 tb.fun2() 这样的定义 没有this(self)

tolua++ 加了对象定义

原文地址:https://www.cnblogs.com/mattins/p/3967018.html