Luabind: getting the super class of a class

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Luabind: getting the super class of a class

Abhijit Nandy
Hi,

I am currently using the original luabind from Rasterbar at https://github.com/luabind/luabind

Its been upgraded for Lua 5.3. I use the object oriented system in Lua that Luabind exposes(the 'class' keyword)

Its working properly except that I can't get the super class of a class defined in Lua.

Has anyone tried this? Currently I solve this by having all class creation & derivation go through my own function so I can track types.

But I am wondering if this information is already there.

e.g.

class 'A'
function A:__init()
end

class 'B'(A)
function B:__init()
end

How to get the super class for B, i.e. A?

Thanks
Abhijit

------------------------------------------------------------------------------

_______________________________________________
luabind-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/luabind-user