Documentation
¶
Overview ¶
Package helpdoc formats the text that lisp:help and the help package print.
It is the single definition of that format. Core lisp:help (package lisp) and the help package's registry functions (lisp/lisplib/libhelp) both write through it, and neither can import the other's rendering: libhelp imports lisp, so lisp cannot import libhelp. Everything here therefore works on text the caller has already rendered, and nothing here imports lisp.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CleanDocRaw ¶
CleanDocRaw dedents a docstring without word-wrapping. JSON consumers get clean text they can format themselves.
func CleanDocstring ¶
CleanDocstring dedents doc, wraps it at 72 columns and indents it two spaces, the layout help prints.
func DedentDoc ¶
DedentDoc removes common leading whitespace from all non-empty lines. It handles Go raw string literals where the first line may have less indentation than continuation lines (which inherit the source code's tab indentation). Tabs are normalized to spaces before processing.
Types ¶
This section is empty.