Documentation Abstract Syntax TreeAuthor(s): Manuel Hermenegildo (original version), Jose F. Morales.
This module defines the intermediate tree representation doctree/1 for documentation and its related operations.
Usage and interface
- Library usage:
cmd_type/1, doctree_is_empty/1, is_nonempty_doctree/1, empty_doctree/1, doctree_insert_end/3, doctree_insert_before_subfile_section/3, doctree_concat/3, doclink_at/2, doclink_is_local/1, section_prop/2, section_select_prop/3, doctree_save/2, doctree_restore/2, doctree_simplify/2, doctree_putvars/5, doctree_scan_and_save_refs/2, doctree_prepare_docst_translate_and_write/3, doctree_to_rawtext/3, doctree_translate_and_write/3, escape_string/4, is_version/1, version_patch/2, version_date/2, version_numstr/2, version_string/2, insert_show_toc/3.
- Regular Types:
doctree/1, doclink/1, doclabel/1, doctokens/1.
- Application modules:
autodoc_state, autodoc_refsdb, autodoc_index, autodoc_structure, autodoc_filesystem, autodoc_settings, comments, autodoc_texinfo, autodoc_man, autodoc_html.
- System library modules:
write, operators, format, pathnames, lists, system_extra, read, terms.
- Internal (engine) modules:
term_basic, arithmetic, atomic_basic, basic_props, basiccontrol, data_facts, exceptions, io_aux, io_basic, prolog_flags, streams_basic, system_info, term_compare, term_typing, hiord_rt, debugger_support.
prelude, nonpure, condcomp, dcg, assertions, regtypes, basicmodes, fsyntax.
- Application modules:
Documentation on exports
Intermediate tree representation for documentation
Insert Elem in A0 at the end, obtaining A
Insert Elem in A0 before the first section, obtaining A. Keep A0 if Elem is already present.
A link to a document label
An internal label
Primitive doctree subset (ready for output, not further reducible)
- Call and exit should be compatible with:
(atm/1)Arg1 is an atom.
(doctree/1)Intermediate tree representation for documentation
- The following properties should hold at call time:
(nonvar/1)Arg1 is currently a term which is not a free variable.
(nonvar/1)Arg2 is currently a term which is not a free variable.
Traverse R0 and replace each var(Name) doctree item with a fresh variable B. For each replacement, the term B=Var is introduced in VarDict, where Var is the associated value to Name in the dictionary PDict.
Escapes needed characters in input string as needed for the target format.
Obtain the string Str representation of version Version (except date)
Obtain the string Str representation of version Version (including date)
Insert the command to show the table of contents in a given doctree/1. The right place may be different depending on the chosen backend.