[slime-devel] Re: Bug in arglist display for unknown functions.

Christophe Rhodes csr21 at cam.ac.uk
Sat Mar 13 11:42:42 UTC 2004


Helmut Eller <e9626484 at stud3.tuwien.ac.at> writes:

> Ivan Boldyrev <boldyrev+nospam at cgitftp.uiggm.nsc.ru> writes:
>
> [snip]
>> If symbol exists, but is not function, error message is different:
>> 
>> (INTEGER -- Error in KERNEL:%COERCE-TO-FUNCTION:  the function INTEGER is undefined.)
>
> What would you like to see instead?  Nothing?  "<not available>"?

Well, if we're wishing...

This commonly happens when we're inside some kind of macro, such as
CASE in Ivan's particular case, or DEFUN (in the arglist).  While it
may not be possible to solve the problem in full generality, for
common-lisp symbols naming macros it is possible to know whether the
user is currently in a region which is directly program text, or
whether he is typing a case matching clause, or an arglist, or a
DEFCLASS slot description.  So given that, in an ideal world, rather
than looking at the nearest open parenthesis, one would look further
back and figure out the semantics of the current form, not just assume
that it's a macro or function call.

On the other hand, firstly I know nothing about emacs programming, so
this may be neither practical nor possible; nor am I volunteering to
learn enough to be able to evaluate this, so please feel free to tell
me that this is way too hard wishlist pie-in-the-sky.

Christophe
-- 
http://www-jcsu.jesus.cam.ac.uk/~csr21/       +44 1223 510 299/+44 7729 383 757
(set-pprint-dispatch 'number (lambda (s o) (declare (special b)) (format s b)))
(defvar b "~&Just another Lisp hacker~%")    (pprint #36rJesusCollegeCambridge)





More information about the slime-devel mailing list