From 46b4c82278029d7193176b72ed3f0d3b1fa8899a Mon Sep 17 00:00:00 2001 From: Jose Antonio Ortega Ruiz Date: Tue, 17 Jan 2017 03:34:33 +0100 Subject: Not inserting a trailing \n when eval prefix is empty And, on reflection, it's better we do the same thing with the ERROR insertion... --- elisp/geiser-mode.el | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/elisp/geiser-mode.el b/elisp/geiser-mode.el index 743855f..6607e86 100644 --- a/elisp/geiser-mode.el +++ b/elisp/geiser-mode.el @@ -67,7 +67,7 @@ active when `geiser-mode' is activated in a buffer." :group 'geiser-mode :type 'boolean) -(geiser-custom--defcustom geiser-mode-eval-to-buffer-prefix "" +(geiser-custom--defcustom geiser-mode-eval-to-buffer-prefix " " "When `geiser-mode-eval-last-sexp-to-buffer', the prefix string which will prepend to results" :group 'geiser-mode :type 'string) @@ -156,13 +156,11 @@ With a prefix, revert the effect of `geiser-mode-eval-last-sexp-to-buffer' " (str (geiser-eval--retort-result-str ret (when will-eval-to-buffer "")))) (cond ((not will-eval-to-buffer) str) ((string= "" str)) - (err (insert (format "\n%sERROR:%s\n" + (err (insert (format "%sERROR:%s" geiser-mode-eval-to-buffer-prefix (geiser-eval--error-str err)))) - (t (progn (push-mark) - (insert (format "%s%s\n" - geiser-mode-eval-to-buffer-prefix - str))))))) + (t (push-mark) + (insert (format "%s%s" geiser-mode-eval-to-buffer-prefix str)))))) (defun geiser-compile-definition (&optional and-go) "Compile the current definition in the Geiser REPL. -- cgit v1.2.3