Matthew Kerwin wrote in post #1101845:
> You can also do this:

Argh, I couldn't let it sit there so wrong.

 def decl cls
   cls.ancestors.reverse.inject do |p,c|
     puts "class #{c} < #{p}"
     puts 'end'
     c  # <<<
   end
 end
 decl A

-- 
Posted via http://www.ruby-forum.com/.