From ff13d973961d14e1695d06ab3768fda8315ffd06 Mon Sep 17 00:00:00 2001 From: Eshel Yaron Date: Mon, 29 Aug 2022 19:59:01 +0300 Subject: [PATCH] DOC: Add CUSTOM_ID properties to README.org headings where needed --- README.org | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/README.org b/README.org index e6450c0..c5dfa3f 100644 --- a/README.org +++ b/README.org @@ -83,6 +83,9 @@ The different parts of =sweep= are structured as follows: SWI-Prolog runtime may need to be built as well. * TODO Prolog initialization and cleanup +:PROPERTIES: +:CUSTOM_ID: prolog-init +:END: #+VINDEX: sweep-init-on-load #+VINDEX: sweep-init-args @@ -138,6 +141,9 @@ close the current query, but =sweep-close-query= also destroys any Prolog bindings created by the query. ** Conversion of Elisp objects to Prolog terms +:PROPERTIES: +:CUSTOM_ID: elisp-to-prolog +:END: =sweep= converts Elisp objects into Prolog terms to allow the Elisp programmers to specify arguments for Prolog predicates invocations (see @@ -154,6 +160,9 @@ we convert /trees of strings and numbers/: are the Prolog representations of the =car= and the =cdr= of the cons. ** Conversion of Prolog terms to Elisp objects +:PROPERTIES: +:CUSTOM_ID: prolog-to-elisp +:END: =sweep= converts Prolog terms into Elisp object to allow efficient processing of Prolog query results in Elisp (see =sweep-next-solution=). @@ -176,6 +185,9 @@ processing of Prolog query results in Elisp (see =sweep-next-solution=). + Prolog dicts are converted to the symbol =dict=. ** Example - counting solutions for a Prolog predicate in Elisp +:PROPERTIES: +:CUSTOM_ID: count-permutations +:END: As an example of using the =sweep= interface for executing Prolog queries, we show an invocation of the non-deterministic predicate @@ -196,6 +208,9 @@ permutations of the list =(1 2 3 4 5)=: * The Prolog top-level +:PROPERTIES: +:CUSTOM_ID: prolog-top-level +:END: #+FINDEX: sweep-top-level =sweep= provides a classic Prolog top-level interface for interacting @@ -227,6 +242,9 @@ command =M-x sweep-find-predicate= jumping to the definition a loaded or auto-loadable Prolog predicate. * Installing Prolog packages +:PROPERTIES: +:CUSTOM_ID: prolog-packages +:END: #+FINDEX: sweep-pack-install The command =M-x sweep-pack-install= can be used to install -- 2.39.5