David Alan Black <dblack / candle.superlink.net> writes: > Hello -- > > I've been puzzling over Ruby's treatment of class variables -- not so > much the "what" as the "why". You bring up some good questions, which leads to only more questions. What does it really mean to be an instance of a class when methods can be dynamically created? I can have 10 actual instances of Car (created with Car.new) and they can have absolutely nothing in common. (Thanks to dynamic addition/removal of interface features, etc.) Given a class, there is no guarnatee that any objects instantiated from it still share its interface at all. It's wishful thinking to assume two objects with the same "base class" have anything in common whatsoever, aside from that base class. Question: Does inheritance honestly have any significant meaning in Ruby? I understand how it searches for names, how inheritance CAN be used, and how all the memory is layed out. I understand the similarities that most instances of classes shares. But I also understand that this is an absolutely false claim in Ruby: "x1 and x2 were both created from class X, therefore x1 and x2 have the same type." I'm not knocking Ruby, I *really* it, but I think that its incredible dynamic power has necessarily caused the impotence of other traditional OO concepts. Nothing comes without a cost. Traditional "is-a" object oriented theory does not apply to Ruby. Ruby is about interfaces, not about types, not about hierarchies. It's not bad, it is just different. -- Chris