From: Chris Pine Date: 2003-02-11T09:38:17+09:00 Subject: Re: turning modules into classes ----- Original Message ----- From: However.... don't forget that Module is a Class object (even though Class is a subclass of Module). That means you haven't derived Class purely from Module -- there's already Class lurking there somewhere. ---------------------------- Hmmm... Well, I was trying to duplicate the *functionality* of Class. Clearly, once Ruby is already running I could never get rid of Class. And it isn't perfect: I don't see any way to prevent multiple inheritance (since you can include many modules into an object). It seems like a chicken-or-the-egg thing. When the interpreter is starting, it must solve this by creating one or the other of them first (Class or Module, I mean), and modifying it later to be dependent upon the other. The only way I see your argument as valid is that FakeClass.new uses Module.new (which is a method Module gets from Class). Otherwise, even though Module *happens* to be a class, I didn't depend upon it. That's still a good point, though. :) I did use Module.new... but I don't see any way around that. Cool! Chris