Closed winterwolf closed 4 years ago
I think I'm starting to understand how it works. It looks like the table is not empty, it just contains non-string keys! I am sorry, it is very difficult for me to understand this code. I really like your library, but I don't like the bloated mess inside it ;(
Yes, the keys are the other class objects
Hello! I inspected your code and its behavior in lovebird. I created a chain of classes, inherited from each other, watched in their
subclasses
fields and all these fields are empty! Maybe I don't get something but I think there is a bug: https://github.com/kikito/middleclass/blob/6102f676c2da6bd395b3c32b1411bb70eea0fac9/middleclass.lua#L154 It sholud look like this:Also I can be wrong, but I feel that for loop in
_propagateInstanceMethod
at lines53
-58
does nothing useful. https://github.com/kikito/middleclass/blob/6102f676c2da6bd395b3c32b1411bb70eea0fac9/middleclass.lua#L53-L57