From: "Wayne E. Seguin" Date: 2007-08-02T00:08:46+09:00 Subject: Re: Help: Get list of modules which are included in the class --Apple-Mail-1--632168353 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed On Aug 01, 2007, at 08:56 , dohzya wrote: > There is a problem (him ! again ! Arrrrrrg (Monthy Python dixit (yeah > for Monthy Ruby !!! (sorry, I'll try to stop lisp-mod ;))))) > You should try this : > --- > module Module1; end > class Class1; include Module1 end > module Module2; end > class Class2 < Class1; include Module1 ; include Module2 end > > Class1.included_modules > Class2.included_modules > > Class1.directly_included_modules > Class2.directly_included_modules # see this result > > Class1.inherited_modules > Class2.inherited_modules > --- > > -- > Etienne Vallette d'Osia Etienne, Good point. Any ideas on a better way? Although if you're including twice like that the design is most likely flawed and needs a re-factoring? -- Wayne E. Seguin Sr. Systems Architect & Systems Admin wayneseguin@gmail.com --Apple-Mail-1--632168353--