From: Eli Zaretskii Date: Fri, 1 Sep 2023 13:33:40 +0000 (+0300) Subject: ; Improve documentation of 'char-table-range' X-Git-Tag: emacs-29.1.90~160 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=5cbe96d17f6;p=emacs.git ; Improve documentation of 'char-table-range' * doc/lispref/sequences.texi (Char-Tables): * src/chartab.c (Fchar_table_range): Clarify what 'char-table-range' returns for an argument that is a cons cell. --- diff --git a/doc/lispref/sequences.texi b/doc/lispref/sequences.texi index dd5b723b479..c9c6bb31350 100644 --- a/doc/lispref/sequences.texi +++ b/doc/lispref/sequences.texi @@ -1645,7 +1645,8 @@ Refers to the element for character @var{char} @item @code{(@var{from} . @var{to})} A cons cell refers to all the characters in the inclusive range -@samp{[@var{from}..@var{to}]}. +@samp{[@var{from}..@var{to}]}. In this case, the function returns the +value for the character specified by @var{from}. @end table @end defun diff --git a/src/chartab.c b/src/chartab.c index 6f0bc28f31b..58bb1658504 100644 --- a/src/chartab.c +++ b/src/chartab.c @@ -580,7 +580,8 @@ DEFUN ("char-table-range", Fchar_table_range, Schar_table_range, 2, 2, 0, doc: /* Return the value in CHAR-TABLE for a range of characters RANGE. RANGE should be nil (for the default value), -a cons of character codes (for characters in the range), or a character code. */) +a cons of character codes (for characters in the range), or a character code. +If RANGE is a cons (FROM . TO), the function returns the value for FROM. */) (Lisp_Object char_table, Lisp_Object range) { Lisp_Object val;