help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: funcallable-p?


From: Drew Adams
Subject: RE: funcallable-p?
Date: Sun, 26 Aug 2007 22:11:50 -0700

> >> > What's a good way to test the first argument to `funcall' or
> >> > `apply', to ensure that it is appropriate?
> >>
> >> `functionp'
> >>
> >> > `functionp' won't do it, because it allows special forms and macros.
> >>
> >> If it does it's a bug: please report it with a precise test case.
>
> > That's the impression I got from 1) the doc and 2) (functionp
> > 'and) -> t, (funcall 'and t) -> Invalid function: and.
>
> > Elisp manual: "This function returns `t' if OBJECT is any kind
> > of function, or a special form, or, recursively, a symbol whose
> > function definition is a function or special form.  (This does
> > not include macros.)"
>
> Indeed you're right.  I think it's an error in functionp.
> Please report it via M-x report-emacs-bug.

I'm not sure what the error is. That is, I don't know what the intended
design is or why. The behavior seems to correspond correctly to the doc, so
I don't know what the bug would be.

If you understand this (I do not) and, as you say, you think it is an error,
then you should perhaps report it as a bug.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]