Adorns an abstract syntax tree with mix-in modules to make accessing the tree more understandable and less implementation-dependent.
# File lib/reek/source/tree_dresser.rb, line 189 def dress(sexp) sexp.extend(SexpNode) module_name = extensions_for(sexp.sexp_type) if SexpExtensions.const_defined?(module_name) sexp.extend(SexpExtensions.const_get(module_name)) end sexp[0..-1].each { |sub| dress(sub) if Array === sub } sexp end
Generated with the Darkfish Rdoc Generator 2.