From ac3b287438e8e5ca85f778f55094822408b1131b Mon Sep 17 00:00:00 2001 From: Jose Antonio Ortega Ruiz Date: Tue, 31 Aug 2010 16:41:45 +0200 Subject: Fix for importing modules at the REPL --- elisp/geiser-repl.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'elisp') diff --git a/elisp/geiser-repl.el b/elisp/geiser-repl.el index adcf03f..ac4413e 100644 --- a/elisp/geiser-repl.el +++ b/elisp/geiser-repl.el @@ -237,6 +237,7 @@ If no REPL is running, execute `run-geiser' to start a fresh one." ((and (not ask) impl (geiser-repl--repl/impl impl))))) (pop-up-windows geiser-repl-window-allow-split)) (cond ((and (eq (current-buffer) repl) + (not (eq repl buffer)) (buffer-live-p geiser-repl--last-scm-buffer)) (pop-to-buffer geiser-repl--last-scm-buffer)) (repl (pop-to-buffer repl)) @@ -278,14 +279,14 @@ module command as a string") module command as a string") (defun geiser-repl-import-module (&optional module) - "Import a given module in the current namespace." + "Import a given module in the current namespace of the REPL." (interactive) (let* ((module (or module (geiser-completion--read-module "Import module: "))) (cmd (and module (geiser-repl--import-cmd geiser-impl--implementation module)))) - (switch-to-geiser) + (switch-to-geiser nil nil (current-buffer)) (geiser-repl--send cmd))) (defun geiser-repl-nuke () -- cgit v1.2.3