Matthias Koeppe mkoeppe+slime@mail.math.uni-magdeburg.de writes:
The solution in the new version of READ-FORM-SPEC is not sufficient, because it does not handle symbols interned in nested forms. [(defmethod (tyy zzz) abcd ...]
Yeah, that was a bug.
In general the "destroy-and-repair" (here: "intern-and-unintern") method is not giving a clean implementation.
I agree that it's not very clean. But it seems to be an acceptable tradeoff to me:
The code now only hard-interns on very obscure occasions (or so I hope!), and should not do so any more than of before my changes on the same instances. And the code does actually deal with `C-c C-s' -- which, as I mentioned already, interned everything previously. And I personally use C-c C-s much more often than stumbling over one of those obscure occasions.
What you need to do -- if you want to use your proposed protocol of sending forms to SWANK -- is implement a limited reader in
(I'm open for suggestions to improve the protocol. I just tried to keep it as simple and as flexible as possible.)
READ-FORM-SPEC. It only needs to handle lists, numbers, strings, and symbols to be useful in this context. It should never intern symbols and gracefully handle what would be a reader error for READ. It should not be very hard to write; give it a try.
I've thought about that before, but how is this supposed to work with `slime-complete-form' without reimplementing a whole reader?
-T.
There's currently a bug I've tried the whole day to track down, but I've not been able to so far:
If you have `(defmethod foo args...)', and have point say at `args', then press C-f, the arglist is displayed endlessly (as can be witnessed if you look into *Messages*.) You may need a bit of experimentation to reproduce it.
I'm perplexed what this could be. (I haven't touched the autodoc caching stuff, and from debugging it seems to work.) I know that it's been introduced by my recent changes, and that it does only occur when tried on one of the specially parsed operators.
Kudos, if you've got an idea, it'd be awesome!