Sorry about my lame mail client.
This is the key: "(loop (swank:create-swank-server 4005))". In=20
threaded mode, this starts up one listening swank server (see
"Swank started at port: 4005." in the output) and then tries to
start another right away, since it's in threaded mode. In previous
versions of slime and SBCL, where create-swank-server was blocking,
at least by default, this code was an easy way to cause swank to
listen again after a slime connection closed. It now has a
parameter to tell it to do this itself.
A heredoc input? Didn't know you could do that. Let's see.
Hmm. It breaks linedit. Disabling...
Yup. Does exactly the same thing with that input, except the
restarts are a little different.
* [chris@... chris]$ sbcl --no-linedit <<EOF
> (require 'asdf)
> (asdf:oos 'asdf:load-op 'swank)
> (loop (swank:create-swank-server 4005))
This is SBCL 0.8.13, an implementation of ANSI Common Lisp.
restarts (invokable by number or by possibly-abbreviated name):
0: [ABORT ] Reduce debugger level (leaving debugger, returning to =
1: [TOPLEVEL] Restart at toplevel READ/EVAL/PRINT loop.
debugger invoked on a SIMPLE-ERROR in thread 15354:
segmentation violation at #X40071276
Same thing, no matter which restart I choose.
I figure this problem could be encountered in situations more serious,
where something you might actually want to happen is trying to happen,
so it's worth looking at and trying to fix. Maybe.
P.S. Seems I forgot to add sbcl-devel back into the To list on my
reply to Nikodemus. Oops. This message has everything that one did,
From: Christophe Rhodes on behalf of Christophe Rhodes
"Chris Capel" <chris@...> writes:
> --eval "(loop (swank:create-swank-server 4005))"
> Processing swank-sbcl.lisp...Processing thread methods...;; Swank =
started at port: 4005.
> debugger invoked on a SB-BSD-SOCKETS:ADDRESS-IN-USE-ERROR in thread =
> Socket error in "bind": EADDRINUSE (Address already in use)
> You can type HELP for debugger help, or (SB-EXT:QUIT) to exit from =
> restarts (invokable by number or by possibly-abbreviated name):
> 0: [CONTINUE] Continue anyway (skipping to toplevel read/eval/print =
> 1: [QUIT ] Quit SBCL (calling #'QUIT, killing the process).
> (SB-BSD-SOCKETS:SOCKET-ERROR "bind")
> 0] 1
OK, so so far what seems to have happened is that you've hit something
else on port 4005. (Maybe a stale slime interaction? Hard to guess,
really -- does it do this from a fresh boot; that is, with no
possibility of a previous try still having some things around?
netstat and lsof may help to find out if you have some stale
Asking to QUIT at this point and getting...
> debugger invoked on a SIMPLE-ERROR in thread 2122:
> segmentation violation at #X40071276
> (no restarts: If you didn't do this on purpose, please report it as a =
> debugger invoked on a TYPE-ERROR in thread 2122:
> The value NIL is not of type SB-DI:FRAME.
... this, followed by a hard exit, isn't ideal. Does it happen that
way if you use a here document (starting sbcl with <<EOF) instead of
http://www-jcsu.jesus.cam.ac.uk/~csr21/ +44 1223 510 299/+44 7729 =
(set-pprint-dispatch 'number (lambda (s o) (declare (special b)) (format =
(defvar b "~&Just another Lisp hacker~%") (pprint =