---- Original message from Joel VanderWerf  on 8/16/2005 5:04 PM:

>Dale Martenson wrote:
>  
>
>>class Module
>>   def lineage
>>       eval self.ancestors.to_s.sub( /::[^:]$/, "" )
>>    
>>
>
>You can use name.sub(...) instead of self.ancestors.to_s.sub(...), but
>it's not much better.
>
>  
>
Actually, it is a lot better since you avoid cases where there are 
additional includes. Module#ancestors
returns an array which causes problems with my original suggestion.

Example:

module X
    include Math
    module Y
        include Comparable
        module Z
            include Enumerable
        end
    end
end

Thanks, Joel for your suggestion. For some reason, Module#name just 
didn't come to mind.