summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjao <jao@gnu.org>2024-07-02 21:13:15 +0100
committerjao <jao@gnu.org>2024-07-02 21:13:15 +0100
commitd5175439c01b177d4f27686e5d6dfdae0505ee1f (patch)
treebc4b5df6781623d70debdc3a1b039efe39ec45d8
parent71a6be00433a157de3936f208c7a1bd0192b12cd (diff)
downloadgeiser-guile-d5175439c01b177d4f27686e5d6dfdae0505ee1f.tar.gz
geiser-guile-d5175439c01b177d4f27686e5d6dfdae0505ee1f.tar.bz2
fix for startup with non-existent last scm buffer
-rw-r--r--geiser-guile.el13
1 files changed, 5 insertions, 8 deletions
diff --git a/geiser-guile.el b/geiser-guile.el
index 558c6bf..a282fa3 100644
--- a/geiser-guile.el
+++ b/geiser-guile.el
@@ -626,10 +626,9 @@ See `geiser-guile-use-declarative-modules'."
(defun geiser-guile--startup (remote)
"Startup function, for a remote connection if REMOTE is t."
(geiser-guile--set-up-error-links)
- (let ((geiser-log-verbose t)
- (g-load-path (buffer-local-value 'geiser-guile-load-path
- (or geiser-repl--last-scm-buffer
- (current-buffer)))))
+ (let* ((last-scm (or geiser-repl--last-scm-buffer (current-buffer)))
+ (geiser-log-verbose t)
+ (g-load-path (buffer-local-value 'geiser-guile-load-path last-scm)))
(when (or geiser-guile--conn-address remote)
(geiser-guile--set-geiser-load-path))
(geiser-guile--set-up-declarative-modules)
@@ -639,12 +638,10 @@ See `geiser-guile-use-declarative-modules'."
(let ((dir (expand-file-name dir)))
(geiser-eval--send/wait `(:eval (:ge add-to-load-path ,dir)))))
(let ((geiser-guile-warning-level
- (buffer-local-value 'geiser-guile-warning-level
- geiser-repl--last-scm-buffer)))
+ (buffer-local-value 'geiser-guile-warning-level last-scm)))
(geiser-guile-update-warning-level))
(let ((geiser-guile-doc-process-texinfo
- (buffer-local-value 'geiser-guile-doc-process-texinfo
- geiser-repl--last-scm-buffer)))
+ (buffer-local-value 'geiser-guile-doc-process-texinfo last-scm)))
(geiser-guile-update-doc-process-texinfo))))