From: ara.t.howard@... Date: 2006-06-16T00:50:43+09:00 Subject: Re: Why the lack of mixing-in support for Class methods? On Fri, 16 Jun 2006, Yukihiro Matsumoto wrote: > Hi, > > In message "Re: Why the lack of mixing-in support for Class methods?" > on Thu, 15 Jun 2006 23:38:24 +0900, Daniel Schierbeck writes: > > |That, and it's nice to have an implementation that fits with the > |interface we have pretty much agreed on (well, matz has). > > Yes, and there's something that only working code can prove. do you think this is important? harp:~ > cat b.rb require 'class_extension' module M class_extension do p const_get(:File) # File p File # File class File def self.inspect() 'my_file' end end p const_get(:File) # File p File # my_file end end p M::File # my_file p M::const_get(:File) # my_file p M::class_extension::const_get(:File) # File p M::class_extension::File # exception! harp:~ > ruby b.rb File File File my_file my_file my_file File b.rb:18: uninitialized constant #::File (NameError) i am in the minority, but it bothers me. don't get me wrong, i like the interface - but the semantics seem odd. regards. -a -- suffering increases your inner strength. also, the wishing for suffering makes the suffering disappear. - h.h. the 14th dali lama