lua-users home
lua-l archive

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

On Tue 16 Oct 2007 02:39:00 PM EDT, Jerome Vuarand wrote:
> Matthew Wilson wrote:
>> I think I understand how the object system in lua works.  Are there
>> any classic examples that show how a prototype-based system surpasses
>> the model used by C++ and Java?  
>> I'm trying to win over some skeptics to Lua, and the object system
>> gets a lot of discussion. 
> Lua itself does not have an object system. You can do both
> prototype-based or class-based OOP in Lua, it's up to you. You can even
> mix both if it suits your needs.

OK, I understand that I can implement class-based OOP in Lua.  Can you
provide any analysis on when prototypes are better or worse than