]> git.eshelyaron.com Git - emacs.git/commitdiff
* Some more `inhibit-native-compile' clean-up
authorAndrea Corallo <akrl@sdf.org>
Mon, 13 Feb 2023 09:26:03 +0000 (10:26 +0100)
committerAndrea Corallo <akrl@sdf.org>
Mon, 13 Feb 2023 10:44:28 +0000 (11:44 +0100)
* lisp/emacs-lisp/generate-lisp-file.el (generate-lisp-file-trailer):
Use `native-comp-deferred-compilation'.

lisp/emacs-lisp/comp.el
lisp/emacs-lisp/generate-lisp-file.el

index 828e31c43bddc8a948a11791a57d795ebc4af200..8a41989237e2234bcbb88484104e34687132cd92 100644 (file)
@@ -4107,14 +4107,12 @@ the deferred compilation mechanism."
                   data
                 ;; So we return the compiled function.
                 (native-elisp-load data)))
-          ;; We may have created a temporary file when we're being
-          ;; called with something other than a file as the argument.
-          ;; Delete it if we can.
           (when (and (not (stringp function-or-file))
                      (not output)
                      comp-ctxt
                      (comp-ctxt-output comp-ctxt)
                      (file-exists-p (comp-ctxt-output comp-ctxt)))
+            ;; NOTE: Not sure if we want to remove this or being cautious.
             (cond ((eq 'windows-nt system-type)
                    ;; We may still be using the temporary .eln file.
                    (ignore-errors (delete-file (comp-ctxt-output comp-ctxt))))
index b2f67ab848d8c92142bf6395aa1b03e78b213196..167cdfbf826fc21be2d03cc64ede0f98f476bf81 100644 (file)
@@ -103,7 +103,7 @@ if it's also byte-compiled)."
       (insert ";; no-byte-" "compile: t\n"))
     (unless autoloads
       (insert ";; no-update-autoloads: t\n"))
-    (when inhibit-native-compile
+    (unless native-comp-deferred-compilation
       (insert ";; no-native-" "compile: t\n"))
     (when coding
       (insert (format ";; coding: %s\n"