Re: reconnecting and *GLOBALLY-REDIRECT-IO*
"Pascal J. Bourguignon" <[email protected]> Mon, 23 Nov 2015 01:56:33 +0100
| Newsgroups | gmane.lisp.slime.devel |
|---|---|
| Organization | Informatimago |
| Message-ID | <[email protected]> |
[email protected] (Gábor Melis) writes: > Hi > > If I connect to a swank server starting simply with: > > (require :swank) > (swank:create-server :port 4095 :dont-close t) > > and evaluate an output producing form such as: > > (loop > (format t "~S~%" *standard-output*) > (sleep 2)) > > then the output is printed to the repl, but after disconnecting and > connecting again the output no longer makes it there. This is seemingly > regardless of the value of *GLOBALLY-REDIRECT-IO* (set in ~/.swank.lisp) > which is contradicting the documentation at > > https://common-lisp.net/project/slime/doc/html/Global-IO-Redirection.html > > Is there a way to get standard streams redirected to the new repl upon > reconnect? AFAIK, there's no global variable holding the slime streams. They're bound to in local lexical variables. Is the looping thread still running after disconnecting? I would expect it to be killed by the disconnection. If *standard-output* wasn't the slime stream itself, but a CL redirecting stream, I don't know that CL implementations block threads trying to do I/O on them until the base thread is again available for I/O. I'm not saying that what you want is impossible, just that it'd require more sophisticated (and more interesting to implement) mechanisms than currently available. -- __Pascal Bourguignon__ http://www.informatimago.com/ “The factory of the future will have only two employees, a man and a dog. The man will be there to feed the dog. The dog will be there to keep the man from touching the equipment.” -- Carl Bass CEO Autodesk