From: Yukihiro Matsumoto Date: 2006-06-15T17:52:31+09:00 Subject: Re: Why the lack of mixing-in support for Class methods? Hi, In message "Re: Why the lack of mixing-in support for Class methods?" on Thu, 15 Jun 2006 17:16:01 +0900, Daniel Schierbeck writes: |Let me get this straight: | | module A | class_extension do | def foo | :foo | end | end | end | | module B | include A | end | | B.foo #=> NoMethodError | |Correct? It would make the implementation a whole lot easier... I meant A.foo would raise NoMethodError. Since class_extension defines a part to inject into the inclusion target, I think B.foo works as natural consequence of inclusion. If B.foo raises an error, it makes class/module separation a lot wider than it currently is. It is an interesting idea though. matz.