Date: 90/07/12 11:38:57
SchemeWEB provides simple support for literate programming in any dialect of Lisp. Originally created for use with Scheme, it defines a new source file format which may be used to produce LATEX input or Lisp code.
SchemeWEB source lines are divided into text and code. Lines of code start with a line beginning with ``('', and continue until the line containing the matching ``)''. The remaining lines are text lines, and they are treated as comments.
When producing a LATEX document, both the text lines and the code
lines are copied into the document source file, but the code lines are
surrounded by a pair of formatting commands (\begin{astyped}
and \end{astyped}
). This LATEX environment formats the code
as written, in typewriter font. A Lisp comment within a code line is
formatted in an \mbox
in Roman font. A SchemeWEB style
command should include the astyped
style option, so that the
astyped
environment is available. An example:
\documentstyle[astyped]{article}
SchemeWEB was designed under the constraint that code lines must be unmodified Lisp code, and text lines must be unmodified LATEX code. Text editors with support for Lisp and LATEX, such as Emacs, may be used for SchemeWEB code much as they are used for Lisp code and LATEX code.
For those who prefer not to modify the reader used by their Lisp system's loader and compiler, the rule that text lines must be unmodified LATEX code has been relaxed. Text lines that begin with ``;'' are copied without the initial ``;''.