sbcl.sbcl/doc
Gabor Melis 4271a2f375 doc: PAXlike docs
Summary
-------

Implement of a subset of PAX so that we can write PAX:DEFSECTIONlike
forms that supports the same restricted Markdown that we use for
docstrings and generate doc/manual/*.texinfo files from them.

Without PAX
-----------

There is no hard dependency on PAX. When the new SB-MANUAL contrib is
loaded, one can M-. around in documentation (sections are variables),
and function docstrings can now link to sections.

The generated Texinfo files are quite close to the originals, with
some loss of "semantic" markup: e.g. Markdown has `FOO` but no
@var{FOO} and @code{FOO}. We didn't derive much practical benefit from
that distinction.

With PAX
--------

(SB-MANUAL::SWITCH-TO-PAX) ensures that PAX is loaded and patches things
up, as if everything had been defined with PAX to begin with. Now, we
get PAX::@BROWSING-LIVE-DOCUMENTATION for low-latency, interactive
documentation work and PAX::@GENERATING-DOCUMENTATION for auto-linked
documentation.

Notable features:

- auto-generated links within the manual: if SB-EXT:EXIT is mentioned,
  then it's linked to its documentation.

- auto-generated links to the CLHS (these links are red in PDF)

- locatives (e.g. the "[function]" in "- [function] SB-EXT:EXIT" are
  also links and they go to the sources on GitHub (in live browsing,
  they tell Slime to open the definition)

Details
-------

- Factor out the Markdown-to-Texinfo code into a new SB-MANUAL
  contrib.

- Convert doc/manual/*.texinfo files to PAXlike DEFSECTION format and
  add each chapter as a contrib/sb-manual/doc/<chapter>.lisp file.

- Fix a *lot* of small issues during the conversion.

- Make doc/make-doc.sh regenerate the all .texinfo files except
  sbcl.texinfo and backmatter.texinfo.

- Fix docstrings of Lisp definitions used in the manual to conform to
  the supported Markdown syntax.

- Retain the Texinfo function, variable and type indicies but drop the
  concept index. There is no obvious way to support that in Markdown,
  and it was used rather sporadically rather incomplete.

- Even with  the new features, the  amount of Lisp code  didn't change
  significantly.

- See contrib/sb-manual/README for the Todo list
2026-06-29 14:01:31 +02:00
..
cmu-user Remove cmu-user.dict 2022-10-03 18:44:01 -04:00
internals Remove sentence which has been untrue for about 5 years 2025-11-09 18:53:29 -05:00
internals-notes Briefly explain the to-be-commited #+linkage-space patch 2024-06-13 17:44:34 -04:00
manual doc: PAXlike docs 2026-06-29 14:01:31 +02:00
clean.sh Tighten up the cd-then-clean.sh idiom. 2021-03-14 19:37:32 +03:00
FOR-CMUCL-DEVELOPERS Remove #\! reader macro 2019-01-30 13:05:59 -05:00
GIT-FOR-SBCL-HACKERS.txt 1.0.20.29: small FIND fix & win32 build fix 2008-09-24 14:55:13 +00:00
GIT-WORKFLOW.md A git-only SBCL workflow 2011-06-06 09:48:08 +03:00
make-doc.sh 1.0.42.51: disable split html manual building 2010-09-21 15:29:10 +00:00
PACKAGING-SBCL.txt Housekeeping: whitespace, typos, comments, credits 2026-05-30 10:57:36 +02:00
README 1.0.13.22: text tweaks 2008-01-10 15:54:04 +00:00
sbcl.1 Document --tls-limit 2026-02-11 11:06:20 +01:00

SBCL is -- ahem! -- imperfectly documented. What can we say? Help with
documentation might not be refused.:-)

There is a Unix man page, sbcl.1.

There is a user manual in texinfo format, in doc/manual/. (In
binary distributions, the compiled-into-HTML translations are also
included.) 

Much of the documentation for supported extensions is in their Lisp
doc strings. For example, to find out how to use the SAVE-LISP-AND-DIE
function in the SB-EXT package, you can execute
  (documentation 'sb-ext:save-lisp-and-die 'function)
or
  (describe 'sb-ext:save-lisp-and-die)
in SBCL.

The user manual is incomplete, and some of its chapters are just notes
that "this is similar to chapter such-and-such of the CMU CL user
manual". The old CMU CL documentation can still be useful both for
missing chapters of the user manual and for documentation of the
internals of the system. It can be downloaded from
<ftp://sbcl.sourceforge.net/pub/sbcl/cmucl-docs.tar.bz2>.