]> git.eshelyaron.com Git - emacs.git/commitdiff
Use 'emacs-lisp-compilation-mode' in native compilation buffers
authorEli Zaretskii <eliz@gnu.org>
Thu, 6 Jul 2023 08:50:41 +0000 (11:50 +0300)
committerStefan Monnier <monnier@iro.umontreal.ca>
Fri, 14 Jul 2023 01:24:24 +0000 (21:24 -0400)
Re-install this commit 40492581f96, now that source of
the recursive-load has been fixed (bug#64494).

* lisp/emacs-lisp/comp.el (comp-log-to-buffer)
(comp-run-async-workers): Use 'emacs-lisp-compilation-mode' in the
buffers where we log the results of native compilation.  Suggested
by No Wayman <iarchivedmywholelife@gmail.com>.  (Bug#64452)

lisp/emacs-lisp/comp.el

index 5f5e7f26446ea2a10da7b106052c1470457a1632..4892733d4565e7181a01fdd0d2933ad1c413c090 100644 (file)
@@ -1133,7 +1133,8 @@ with `message'.  Otherwise, log with `comp-log-to-buffer'."
          (log-buffer
              (or (get-buffer comp-log-buffer-name)
                  (with-current-buffer (get-buffer-create comp-log-buffer-name)
-                   (setf buffer-read-only t)
+                   (unless (derived-mode-p 'compilation-mode)
+                     (emacs-lisp-compilation-mode))
                    (current-buffer))))
          (log-window (get-buffer-window log-buffer))
          (inhibit-read-only t)
@@ -4085,7 +4086,8 @@ display a message."
                              :buffer (with-current-buffer
                                          (get-buffer-create
                                           comp-async-buffer-name)
-                                       (setf buffer-read-only t)
+                                       (unless (derived-mode-p 'compilation-mode)
+                                         (emacs-lisp-compilation-mode))
                                       (current-buffer))
                              :command (list
                                        (expand-file-name invocation-name
@@ -4119,6 +4121,8 @@ display a message."
     (run-hooks 'native-comp-async-all-done-hook)
     (with-current-buffer (get-buffer-create comp-async-buffer-name)
       (save-excursion
+        (unless (derived-mode-p 'compilation-mode)
+          (emacs-lisp-compilation-mode))
         (let ((inhibit-read-only t))
           (goto-char (point-max))
           (insert "Compilation finished.\n"))))