From: Dennis Decker Jensen Date: 2001-05-11T23:15:54+09:00 Subject: [ruby-talk:14999] SV: Re: Class/Module Information Hi, Dave Thomas wrote: | matz@zetabits.com (Yukihiro Matsumoto) writes: | | > So there're three separate (but related) possible RCRs: | > | > Module#included_modules(includeIndirect=true) | > Module#constants(includeSuper=true) | > Module#class_variables(includeSuper=true) | | Before we go too far down this road, is it possible that there's | another way of doing this altogether? | | Say we had Object#reflection, which returned an object of type | ObjectReflector. This could provide all the various introspection | methods in one tidy place [good example] | This seems tidier to me, and sets a precedent should we ever allow | other forms of reflection. If introspection or reflection in Ruby is going to grow, this sounds like a extremely good suggestion. Is it going to? Mostly I find code with introspection hard to read and understand -- even in Ruby...:). Something like ObjectReflector would help I think if more introspection is on its way... -- Dennis Decker Jensen