module CSL::PrettyPrinter
Public Instance Methods
Source
# File lib/csl/pretty_printer.rb, line 12 def pretty_print preamble << tags.map { |t| pp t }.join("\n") end
Private Instance Methods
Source
# File lib/csl/pretty_printer.rb, line 26 def pp(tag, level = 0) if tag.is_a?(Array) tag.map { |t| pp t, level + 1 }.join("\n") else (' ' * (level * tabwidth)) << tag.to_s end end