lua-users home
lua-l archive

Re: Idea: Reference Libraries

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


Am 22.04.2014 08:40 schröbte Dirk Laurie:
2014年04月22日 8:20 GMT+02:00 Andrew Starks <andrew.starks@trms.com>:
Typically when "blessed" comes up, it is in terms of "standard socket
library" and "class implementation."
Class implementation in Lua is a perfect example of a subject over which
religious wars are fought. Is the class table the metatable or the __index
metamethod of the object? Sheep to my right, goats to my left, please.
Neither if done right ;-p. But why should we care? If `Animal` is a class, I want
 function Animal:speak() ... end
to somehow end up as a method for Animal objects.
Philipp

AltStyle によって変換されたページ (->オリジナル) /