summaryrefslogtreecommitdiff
path: root/doc/lispref/functions.texi
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2022-05-11 10:13:09 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2022-05-11 10:18:12 -0700
commit4f27e4ff02d9d96b5cfbd196dd724e4a056cd8ef (patch)
tree10075770ba0daf732360fe37b379b9e78414937b /doc/lispref/functions.texi
parent678e05e851af9e5b1fdc50d7d2a661b33ad663d5 (diff)
downloademacs-4f27e4ff02d9d96b5cfbd196dd724e4a056cd8ef.tar.gz
emacs-4f27e4ff02d9d96b5cfbd196dd724e4a056cd8ef.tar.bz2
emacs-4f27e4ff02d9d96b5cfbd196dd724e4a056cd8ef.zip
functionp doc improvement
* doc/lispref/eval.texi, doc/lispref/functions.texi, src/eval.c: Document functionp a bit more carefully. It can return t on non-functions.
Diffstat (limited to 'doc/lispref/functions.texi')
-rw-r--r--doc/lispref/functions.texi7
1 files changed, 6 insertions, 1 deletions
diff --git a/doc/lispref/functions.texi b/doc/lispref/functions.texi
index 2f386eaa47e..55bbf8fd5a2 100644
--- a/doc/lispref/functions.texi
+++ b/doc/lispref/functions.texi
@@ -146,7 +146,12 @@ function:
This function returns @code{t} if @var{object} is any kind of
function, i.e., can be passed to @code{funcall}. Note that
@code{functionp} returns @code{t} for symbols that are function names,
-and returns @code{nil} for special forms.
+and returns @code{nil} for symbols that are macros or special forms.
+
+If @var{object} is not a function, this function ordinarily returns
+@code{nil}. However, the representation of function objects is
+complicated, and for efficiency reasons in rare cases this function
+can return @code{t} even when @var{object} is not a function.
@end defun
It is also possible to find out how many arguments an arbitrary