Lua Class System (LCS) is a small library which offers a clean, minimalistic but powerful API for (Pseudo) Object Oriented programming style using Lua.
Hi Yonaba, I really like your class system! However, all the LCS methods like extends, is_A, getSubClasses, etc. are put right into the tables for instances of my class. You pollute my instances' tables with LCS library methods instead of tucking them away in the index metatable where I believe they belong. Looking over your code, it looks like you reserve the index table for inheritance. Perhaps there is another solution in which you set __index to a function that accesses the base class as well as LCS methods? I'd love to here you're thoughts on this design decision. Thanks!
Hi Yonaba, I really like your class system! However, all the LCS methods like extends, is_A, getSubClasses, etc. are put right into the tables for instances of my class. You pollute my instances' tables with LCS library methods instead of tucking them away in the index metatable where I believe they belong. Looking over your code, it looks like you reserve the index table for inheritance. Perhaps there is another solution in which you set __index to a function that accesses the base class as well as LCS methods? I'd love to here you're thoughts on this design decision. Thanks!