[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
is this a bug?
From: |
David Roderick |
Subject: |
is this a bug? |
Date: |
Fri, 28 Mar 2008 21:27:48 +0000 |
User-agent: |
Gnus/5.11 (Gnus v5.11) Emacs/22.0.990 (windows-nt) |
9.2.4 Symbol Function Indirection
---------------------------------
-- Function: indirect-function function &optional noerror
This function returns the meaning of FUNCTION as a function. If
FUNCTION is a symbol, then it finds FUNCTION's function definition
and starts over with that value. If FUNCTION is not a symbol,
then it returns FUNCTION itself.
This function signals a `void-function' error if the final symbol
is unbound and optional argument NOERROR is `nil' or omitted.
Otherwise, if NOERROR is non-`nil', it returns `nil' if the final
symbol is unbound.
It signals a `cyclic-function-indirection' error if there is a
loop in the chain of symbols.
Here is how you could define `indirect-function' in Lisp:
(defun indirect-function (function)
(if (symbolp function)
(indirect-function (symbol-function function))
function))
shouldn't this be?
(defun indirect-function (function)
(if (symbolp function)
(symbol-function function)
(function))
--
from
David Roderick
- is this a bug?,
David Roderick <=