* Doc string for `sort'
@ 2005-06-16 14:21 Kim F. Storm
2005-06-16 22:12 ` Richard Stallman
0 siblings, 1 reply; 2+ messages in thread
From: Kim F. Storm @ 2005-06-16 14:21 UTC (permalink / raw)
The doc string for `sort' has the following requirement:
Returns the sorted list. LIST is modified by side effects.
PREDICATE is called with two elements of LIST, and should return t
if the first element is "less" than the second. */)
The lisp ref, says the same thing:
The argument PREDICATE must be a function that accepts two
arguments. It is called with two elements of LIST. To get an
increasing order sort, the PREDICATE should return `t' if the
first element is "less than" the second, or `nil' if not.
Looking at the code, PREDICATE just need to return non-nil;
so is there a reason why the doc string says the return
value should be `t' rather than any non-`nil' value?
--
Kim F. Storm <storm@cua.dk> http://www.cua.dk
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Doc string for `sort'
2005-06-16 14:21 Doc string for `sort' Kim F. Storm
@ 2005-06-16 22:12 ` Richard Stallman
0 siblings, 0 replies; 2+ messages in thread
From: Richard Stallman @ 2005-06-16 22:12 UTC (permalink / raw)
Cc: emacs-devel
Looking at the code, PREDICATE just need to return non-nil;
so is there a reason why the doc string says the return
value should be `t' rather than any non-`nil' value?
No reason--you could fix the docs if you want.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2005-06-16 22:12 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-06-16 14:21 Doc string for `sort' Kim F. Storm
2005-06-16 22:12 ` Richard Stallman
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.