[slime-devel] broken clojure REPL
Tobias C. Rittweiler
tcr at freebits.de
Tue Nov 17 20:04:21 UTC 2009
"Stefan Kamphausen" <skampi at gmx.net> writes:
> First and most important to me is the line
> (defconst slime-cursor-marker 'swank::%cursor-marker%)
> from contrib/slime-parse.el. If I tracked things correctly this
> symbol gets inserted in the form sent to swank, which is passed to
> arglist-for-echo-area by the swank-evaluation mechanism. This seems
> to rely on the fact that "swank::%cursor-marker%" is a valid name in
> the backend. Surely, this is true for CL-backends, unfortunately not
> for Clojure. There "::" should be a "/" and the "%"s are not allowed.
> Please see http://groups.google.com/group/clojure/t/eef10af52a619eee
> for a thread on the Clojure-list.
> While I understand that it would be nice to have a real symbol
> denoting the current cursor position, it feels rather hackish to me
> (and it /kills/ the swank-threads in Clojure). Would you mind replacing
> it with a not-so-special string? As far as I can tell, the code
> wouldn't need to change too much (cases of eq would probably become
> string= or something like that in a few places, but I may be wrong).
Using true symbols feels hackish to you but using strings which may
legitimately appear as buffer forms does not? Uhm. :-)
Clojure seems to conflate how symbols are named, and how they're read
in. Is there no way to escape symbol names?
> What remains then is an error message from eldoc, e.g.
> eldoc error: (wrong-type-argument listp [string file line))
> I still have to find the piece of code that throws this, but it seems
> to be related to braces and brackets, some code seems to rely on
> parens being the only kind of parenthesis.
Backtrace? You have to make sure that ?\[ has a syntax-type "(", and ?\]
a syntax-type ")" by using `modify-syntax-entry'.
More information about the slime-devel