From: Eshel Yaron Date: Sat, 14 Jan 2023 07:05:58 +0000 (+0200) Subject: Add a couple of missing docstrings X-Git-Tag: V9.1.3-sweep-0.11.3~9 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=3e02ab91fd4b28ad5a86eec03bcce80ca662cf61;p=sweep.git Add a couple of missing docstrings * sweeprolog.el (sweeprolog-read-predicate-documentation-with-holes) (sweeprolog-read-predicate-documentation-default-function): add docstrings. --- diff --git a/sweeprolog.el b/sweeprolog.el index e62db75..3e95d9f 100644 --- a/sweeprolog.el +++ b/sweeprolog.el @@ -3286,16 +3286,19 @@ predicate definition at or directly above POINT." term)))))) term))) -(defun sweeprolog-read-predicate-documentation-with-holes (fun ari) - (list (sweeprolog-format-term-with-holes fun ari) +(defun sweeprolog-read-predicate-documentation-with-holes + (functor arity) + "Use holes for initial documentation for predicate FUNCTOR/ARITY." + (list (sweeprolog-format-term-with-holes functor arity) (sweeprolog--hole "Det") nil)) -(defun sweeprolog-read-predicate-documentation-default-function (fun - ari) +(defun sweeprolog-read-predicate-documentation-default-function + (functor arity) + "Prompt for initial documentation for predicate FUNCTOR/ARITY." (let ((cur 1) (arguments nil)) - (while (<= cur ari) + (while (<= cur arity) (let ((num (pcase cur (1 "First") (2 "Second") @@ -3313,7 +3316,7 @@ predicate definition at or directly above POINT." (?m "multi" "Succeeds at least once") (?u "undefined" "Undefined"))))) (summary (read-string "Summary: "))) - (list (concat (sweeprolog-format-string-as-atom fun) + (list (concat (sweeprolog-format-string-as-atom functor) (if arguments (concat "(" (mapconcat #'identity arguments ", ")