]> git.eshelyaron.com Git - emacs.git/commitdiff
Improve recently added documentation
authorEli Zaretskii <eliz@gnu.org>
Tue, 21 Sep 2021 18:51:38 +0000 (21:51 +0300)
committerEli Zaretskii <eliz@gnu.org>
Tue, 21 Sep 2021 18:51:38 +0000 (21:51 +0300)
* doc/lispref/lists.texi (Building Lists):
* lisp/subr.el (ensure-list): Avoid passive tense in documenting
'ensure-list'.

doc/lispref/lists.texi
lisp/subr.el

index 6bb11460efe22620f71e364c32c789cda1292d34..75641256b60d9839e2e039d091a0758f1cbd8d8f 100644 (file)
@@ -680,9 +680,9 @@ list are in the same order as in @var{tree}.
 @end example
 
 @defun ensure-list object
-Ensure that we have a list.  If @var{object} is already a list, it is
-returned.  If @var{object} isn't a list, a one-element list containing
-@var{object} is returned.
+This function returns @var{object} as a list.  If @var{object} is
+already a list, the function returns it; otherwise, the function
+returns a one-element list containing @var{object}.
 
 This is usually useful if you have a variable that may or may not be a
 list, and you can then say, for instance:
index 232e684cd4650c78e39ec218da3d8f83031353fc..0793cbca5e1ed380dcec8c452944d1b8cb7f28a0 100644 (file)
@@ -6427,9 +6427,9 @@ This is intended for internal use only."
          (json-unavailable nil))))
 
 (defun ensure-list (object)
-  "Ensure that we have a list.
-If OBJECT is already a list, OBJECT is returned.  If it's
-not a list, a one-element list containing OBJECT is returned."
+  "Return OBJECT as a list.
+If OBJECT is already a list, return OBJECT itself.  If it's
+not a list, return a one-element list containing OBJECT."
   (if (listp object)
       object
     (list object)))