emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/macrostep 9a534df 052/110: Make macrostep-slime-insert mor


From: ELPA Syncer
Subject: [nongnu] elpa/macrostep 9a534df 052/110: Make macrostep-slime-insert more robust
Date: Sat, 7 Aug 2021 09:18:01 -0400 (EDT)

branch: elpa/macrostep
commit 9a534df7a47659b2f4cadd565d412b4a32e8372d
Author: Luís Oliveira <loliveira@common-lisp.net>
Commit: Luís Oliveira <loliveira@common-lisp.net>

    Make macrostep-slime-insert more robust
    
    * macrostep.el (macrostep-slime-insert): Don't assume `forward-sexp'
      knows how to jump over the expansion and store the point after
      insertion instead.
---
 macrostep.el | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/macrostep.el b/macrostep.el
index 80ef41a..467d878 100644
--- a/macrostep.el
+++ b/macrostep.el
@@ -926,11 +926,13 @@ expansion will not be fontified.  See also
 (defun macrostep-slime-insert (expansion)
   "Insert EXPANSION at point, indenting to match the current column."
   (let* ((indent-string (concat "\n" (make-string (current-column) ? )))
-         (expansion (replace-regexp-in-string "\n" indent-string expansion)))
+         (expansion (replace-regexp-in-string "\n" indent-string expansion))
+         (end-point))
     (save-excursion
-      (insert expansion))
+      (insert expansion)
+      (setq end-point (point)))
     (macrostep-slime--propertize-macros)
-    (forward-sexp)))
+    (goto-char end-point)))
 
 (defun macrostep-slime--propertize-macros ()
   "Put text properties on macros in the form following point."



reply via email to

[Prev in Thread] Current Thread [Next in Thread]