Skip to main content

Module printer

Module printer 

Source
Expand description

The printer: VLA.bas’s WriteDatum and WritePretty.

WriteDatum writes a form flat: a symbol as it stands, a string literal quoted with \ and " escaped (backslashes first), a list in parentheses with one space between elements, and () for an empty one. WritePretty is VlaExpandText’s and VlaFormat’s layout: a form that fits within 90 columns at its indent prints flat; a wider list opens with its head and gives every remaining element its own line four columns in, closing on the last. Width is measured as VBA’s Len measures it, in UTF-16 code units.

Functions§

write_datum
VBA WriteDatum.
write_pretty
VBA WritePretty, with lines joined by CRLF as the VBA joins them.