Ahoy,
Currently it is possible for a Lisp image to support multiple SLIME connections. Are we using this functionality, and if so how?
Originally it was used to support a connection-per-thread model, but that has been replaced and now all threads share a single multiplexed connection.
I was thinking of deleting the 'connection' record and moving its fields into global variables. Thoughts?
-Luke
Luke Gorrie luke@bluetail.com writes:
Currently it is possible for a Lisp image to support multiple SLIME connections. Are we using this functionality, and if so how?
It's currently the only way to get multiple listeners in the same image. It is also used by slime-attach-thread.
It seems that the current design of the REPL and stream redirection should be generalized to support multiple listeners. The mk-defsystem/polling issue is also an indicator that there is something not quite right.
I was thinking of deleting the 'connection' record and moving its fields into global variables. Thoughts?
The protocol code is currently a bit difficult to read, even if the functionality itself is relatively simple. The function fields (read, send etc.) in the structure are probably the most confusing part, but it is hard to support different communications styles without some form of indirection. Hard to say if global variables would increase readability.
The idea of per-connection variables as we have them on the Emacs side doesn't sound so terrible to me. The fields in the connection struct can be viewed as such variables. In some way it's also cute that *emacs-connection* is not globally bound (it is only globally accessible to support the global debugger hook).
If you can rewrite the protocol code more readably, please do so. I don't see a good way.
Helmut.