[slime-devel] [BUG] ed-in-emacs on symbols

Terje Norderhaug terje at in-progress.com
Thu Jul 2 07:43:02 UTC 2009

The ed-in-emacs function may err when given certain symbols as  
argument. In particular, multiple escaped characters in a symbol can  
trip it up.

For example, with AquaMacs + Clozure:

(ed 'a\ b\ c)
=> error in process filter: Wrong number of arguments: NIL, 3

(ed-in-emacs '|ab)c|)
=> error in process filter: No known definition for: common-lisp- 
user::ab (in nil)

The cause is that ed-in-emacs attempts to pass the raw symbol when  
dispatching :ED to emacs:

1. dispatch-event: (:EMACS-REX (SWANK:LISTENER-EVAL "(ed 'a\\ b\\  
2. send-event: #<PROCESS repl-thread(36)> (:EMACS-REX (SWANK:LISTENER- 
EVAL "(ed 'a\\ b\\ c)") "COMMON-LISP-USER" 74)
3. dispatch-event: (:ED COMMON-LISP-USER::|A B C|)
4. WRITE: (:ed common-lisp-user::|A B C|)

Common LISP typically outputs a symbol using bars for |multiple  
escape|. However, this is not understood by the emacs reader.

How can we change the encoding of the :ED dispatch symbol argument to  
fix this issue?

-- Terje Norderhaug 

More information about the slime-devel mailing list