Lua class support

Issue #13 new
Ilia Pavlovets
created an issue

Liam, what about "inbox" support of OOP in Lua? I've found that "luabind" has this feature. Is this possible to do it in OOLua? Luabind - I've started using Luabind at my new job, but in my own projects I'm using OOLua and OOP support will help a bit.

Comments (6)

  1. Liam Devine repo owner

    It is pretty much possible to do anything for the library yet the real question is if it should be done.

    Could you expand on what you mean by "inbox" support of OOP in Lua? For example are you just looking for the ability to create a "class" in Lua or are you wanting to derive from a C++ class, override virtual methods and maybe pass a Lua "class" to C++ where it is auto-magically cast to the C++ object?

    ""luabind" has this feature" -- Hehe. It is also slow, unmaintained, requires boost ... I wonder if I should follow suit :P

  2. Istvan Papp

    Hi Liam, actually I would like to be able to derive a class in Lua from a C++. Is this feature supported by OOLua?

    Additionally, what is the minimum binary size of OOLua + Lua on e.g. Linux? I am developing for a constrained embedded platform, so it would be good to know.

    Thanks, Istvan.

  3. Liam Devine repo owner

    @Istvan Papp as it currently stands that functionality is not supported, hence this feature request. With regards to the binary size of the libraries it would very much depend on which features you enable, the type of optimisation used when compiling and what, if anything, you removed from Lua.

  4. Ilia Pavlovets reporter

    If it is possible to implement both variants (Lua class and C++ expansion) - it will be the best! PS I agree, luabind is ugly. That was no my decision to use it. =)

  5. Log in to comment