lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


We know v:name(args)  is syntactic sugar for v.name(v,args) .

Could we make this syntactic sugar more flexible ? like this :

v:x.name(args) -> v.x.name(v, args)

Maybe it will be more useful especially when v is an userdata with complex structures.

v.x can be a type object rather than a value belongs to v ( v1.x == v2.x when the type of v1 is the same with v2)