From: Chris Carter Date: 2007-07-14T12:24:44+09:00 Subject: Re: Inheritable mixin On 7/13/07, Yukihiro Matsumoto wrote: > Hi, > > In message "Re: Inheritable mixin" > on Sat, 14 Jul 2007 05:14:02 +0900, TRANS writes: > > |What do you think of making Class not inherit Module, but instead make > |them separate classes that both mixin "Inheritable" (or whatever you'd > |like to call it)? > > By separating modules and classes, we get class hierarchy design > clarity at the cost of little bit language complexity. Making > mixin (modules) inheritable means introducing "full" multiple > inheritance in the language. I don't think it's worth changing the > language we live happily without full MI. > > |The thought occurred to me while organizing Facets. I've been locking > |at what methods might fit together into organization units, ie, > |mixins, so far I've been able to successfully develop Indexable and > |Stackable. > > More concrete example please? I am not sure the benefit of having > > module Indexable > end > > class Whatever < Indexable > end > > over > > class Whatever > include Indexable > end > > matz. > > > > Matz, I believe he meant that it would be a mixin named Inheritable, so: class Class include Inheritable end class Module include Inheritable end -- Chris Carter concentrationstudios.com brynmawrcs.com