cvs server: Diffing . Index: slime.el =================================================================== RCS file: /project/slime/cvsroot/slime/slime.el,v retrieving revision 1.195 diff -u -r1.195 slime.el --- slime.el 21 Jan 2004 22:00:33 -0000 1.195 +++ slime.el 21 Jan 2004 23:38:19 -0000 @@ -3971,6 +3986,18 @@ (t (error "Busy - can't attach in current state (%S)" (slime-current-state))))) + +(defun slime-repl-set-package (package) + "Sets the package of the REPL buffer to PACKAGE." + (interactive (list (slime-read-package-name "Package: " + (slime-find-buffer-package)))) + (with-current-buffer (slime-output-buffer) + (let ((unfinished-input (slime-repl-current-input))) + (slime-mark-output-start) + (slime-with-output-end-mark + (slime-eval `(swank:set-repl-package ,package)) + (slime-repl-insert-prompt "") + (insert unfinished-input))))) (defun slime-set-package (package) (interactive (list (slime-read-package-name "Package: " Index: swank.lisp =================================================================== RCS file: /project/slime/cvsroot/slime/swank.lisp,v retrieving revision 1.107 diff -u -r1.107 swank.lisp --- swank.lisp 21 Jan 2004 23:26:32 -0000 1.107 +++ swank.lisp 21 Jan 2004 23:38:19 -0000 @@ -762,6 +762,12 @@ (setq *package* (guess-package-from-string package)) (package-name *package*)) +(defslimefun set-repl-package (package) + "Sets package of the REPL to PACKAGE and reports back to emacs." + (setq *package* (guess-package-from-string package)) + (send-to-emacs + `(:new-package ,(shortest-package-nickname *package*)))) + (defslimefun listener-eval (string) (clear-user-input) (multiple-value-bind (values last-form) (eval-region string t)