module documentation
(source)

Conversion of parse tree nodes to strings.
Class ​Str​Conv Visitor for converting a node to a human-readable string.
Function dump​_tagged Convert an array into a pretty-printed multiline string representation.
Function indent Indent all the lines in s (separated by newlines) by n spaces.
def dump_tagged(nodes, tag, str_conv): (source)

Convert an array into a pretty-printed multiline string representation.

The format is
tag(
item1.. itemN)
Individual items are formatted like this:
  • arrays are flattened
  • pairs (str, array) are converted recursively, so that str is the tag
  • other items are converted to strings and indented
Parameters
nodes:Sequence[object]Undocumented
tag:Optional[str]Undocumented
str​_conv:StrConvUndocumented
Returns
strUndocumented
def indent(s, n): (source)
Indent all the lines in s (separated by newlines) by n spaces.
Parameters
s:strUndocumented
n:intUndocumented
Returns
strUndocumented