Created
January 27, 2016 18:10
-
-
Save cbaggers/64b79395c26b01998127 to your computer and use it in GitHub Desktop.
update-swank
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun update-swank () | |
"Called from within the main loop, this keep the lisp repl | |
working while cepl runs" | |
(continuable | |
(let ((connection (or swank::*emacs-connection* | |
(swank::default-connection)))) | |
(when connection | |
(swank::handle-requests connection t))))) | |
(defmacro continuable (&body body) | |
"Helper macro that we can use to allow us to continue from an | |
error. Remember to hit C in slime or pick the restart so | |
errors don't kill the app." | |
`(restart-case | |
(progn ,@body) | |
(continue () :report "CEPL Continue"))) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment