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

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

[nongnu] elpa/rust-mode 1398c0b2b2 3/4: Merge pull request #479 from ntB


From: ELPA Syncer
Subject: [nongnu] elpa/rust-mode 1398c0b2b2 3/4: Merge pull request #479 from ntBre/master
Date: Sun, 25 Dec 2022 17:59:33 -0500 (EST)

branch: elpa/rust-mode
commit 1398c0b2b233b5c4fb25363c8cfa11f9539f182f
Merge: 384051e23f 4f7581d4c3
Author: brotzeit <brotzeitmacher@gmail.com>
Commit: GitHub <noreply@github.com>

    Merge pull request #479 from ntBre/master
    
    check for rustfmt window before deleting it, fixes the fix to #475
---
 rust-rustfmt.el | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/rust-rustfmt.el b/rust-rustfmt.el
index ff5ba25188..de618cb9a9 100644
--- a/rust-rustfmt.el
+++ b/rust-rustfmt.el
@@ -69,7 +69,10 @@
                         (with-current-buffer buf
                           (replace-buffer-contents rust-rustfmt-buffername))
                       (copy-to-buffer buf (point-min) (point-max))))
-                (kill-buffer-and-window))
+               (let ((win (get-buffer-window rust-rustfmt-buffername)))
+                 (if win
+                     (quit-window t win)
+                   (kill-buffer rust-rustfmt-buffername))))
                ((= ret 3)
                 (if (not (string= (buffer-string)
                                   (with-current-buffer buf (buffer-string))))



reply via email to

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