This is the mstrings Reference Manual, version 0.1.1, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Dec 15 07:07:08 2024 GMT+0.
The main system appears first, followed by any subsystem dependency.
mstrings
Pretty multiline strings Reader Macro
Samuel Hunter
(GIT https://git.sr.ht/~shunter/mstrings/)
BSD 3-Clause
Mstrings defines a reader macro for strings with a small handful of features to provide visually appealing multiline blocks.
0.1.1
named-readtables
(system).
mstrings.lisp
(file).
Files are sorted by type and then listed depth-first from the systems components trees.
mstrings/mstrings.lisp
mstrings
(system).
mstring-reader
(function).
do@
(macro).
peek-char!
(function).
read-char!
(function).
read-folding-mstring
(function).
read-line-until-delim
(function).
read-literal-mstring
(function).
skip-empty-lines
(function).
skip-spaces
(function).
whitespacep
(function).
Packages are listed by definition order.
xyz.shunter.mstrings
Reader macro for friendlier multiline strings
mstrings
common-lisp
.
mstring-reader
(function).
do@
(macro).
peek-char!
(function).
read-char!
(function).
read-folding-mstring
(function).
read-line-until-delim
(function).
read-literal-mstring
(function).
skip-empty-lines
(function).
skip-spaces
(function).
whitespacep
(function).
Definitions are sorted by export status, category, package, and then by lexicographic order.
Multiline string reader function to be installed as a dispatching macro character.
It ignores and warns on any provided ARG, and provides a few quality-of-life features depending on the value of SUBCHAR:
- If SUBCHAR is #\", it is always literal-block mode (‘#M"..."‘) and reads the rest of the string.
- If SUBCHAR is #\>, it is always folding-block mode (‘#M>"..."‘).
- If SUBCHAR is anything else, it reverts to its default behavior: it assumes literal-block mode unless there is a greater-than-sign preceding the string, in which case it switches to folding-block mode.
Anaphoric DO. An @ in the then-form replays the init-form.
Read mstring contets from STREAM until a Newline or string delimiter ".
Read from STREAM until it consumes a Newline or reaches the string delimiter ", and write to OUT.
Escaped quotes and whitespaces are treated as a non-whitespace character.
Returns two values:
- Whether there should be a linebreak at the block mode’s discretion;
- Whether it has written any contents to OUT.
Skip all lines that contain only unescaped whitespaces, and write them out as a singular Newline. Return whether any newlines were written.
Skip until the first Newline or non-whitespace character and return it, unconsumed.
Jump to: | D F M P R S W |
---|
Jump to: | D F M P R S W |
---|
Jump to: | F M P S X |
---|
Jump to: | F M P S X |
---|