[slime-devel] M-x slime to go back to the REPL

Pascal J.Bourguignon pjb at informatimago.com
Sun Jun 20 06:21:48 UTC 2004


Both ilisp and run-lisp when invoked a second time switch back to
their buffer.  slime did not.  Now it does too:


(defun slime ()
  "Start an inferior^_superior Lisp and connect to its Swank server,
or switch to the slime REPL buffer if it's already running."
  (interactive)
  (if (get-buffer-process (get-buffer "*inferior-lisp*"))
    (switch-to-buffer (slime-output-buffer))
    (when (or (not (slime-bytecode-stale-p))
              (slime-urge-bytecode-recompile))
      (cond ((and current-prefix-arg
                  (slime-connected-p)
                  (get-buffer "*inferior-lisp*"))
             (unless (slime-maybe-rearrange-inferior-lisp)
               (slime-disconnect)))
            (t (slime-disconnect)))
      (slime-maybe-start-lisp)
      (slime-read-port-and-connect))))


-- 
__Pascal Bourguignon__                     http://www.informatimago.com/

There is no worse tyranny than to force a man to pay for what he does not
want merely because you think it would be good for him. -- Robert Heinlein




More information about the slime-devel mailing list