]> git.eshelyaron.com Git - emacs.git/commitdiff
Command late load when deferring compilation
authorAndrea Corallo <akrl@sdf.org>
Wed, 18 Mar 2020 21:20:52 +0000 (21:20 +0000)
committerAndrea Corallo <akrl@sdf.org>
Thu, 19 Mar 2020 13:50:25 +0000 (13:50 +0000)
lisp/emacs-lisp/comp.el
src/comp.c

index f1e99c5ee165c7e4c492f668e716d3670772fac1..44de2745c6cdf290ac8f2ddd3f2b11f0f9aa5988 100644 (file)
@@ -41,7 +41,9 @@
   :group 'lisp)
 
 (defcustom comp-deferred-compilation nil
-  "If t compile asyncronously all lexically bound .elc files being loaded."
+  "If t compile asyncronously all lexically bound .elc files being loaded.
+Once compilation happened each function definition is updated to
+the native compiled one."
   :type 'boolean
   :group 'comp)
 
index 3f2b45c85fdc56f72475d3eb5fbe6da62415bb15..d645b59590fc016cba505e745df35f454cc72f56 100644 (file)
@@ -3381,7 +3381,8 @@ maybe_defer_native_compilation (Lisp_Object function_name,
     concat2 (CALL1I (file-name-sans-extension, Vload_file_name),
             build_pure_c_string (".el"));
   if (!NILP (Ffile_exists_p (src)))
-    CALLN (Ffuncall, intern_c_string ("native-compile-async"), src, Qnil);
+    CALLN (Ffuncall, intern_c_string ("native-compile-async"), src, Qnil,
+          Qlate);
 }
 
 \f
@@ -3639,6 +3640,7 @@ syms_of_comp (void)
   /* Others.  */
   DEFSYM (Qfixnum, "fixnum");
   DEFSYM (Qscratch, "scratch");
+  DEFSYM (Qlate, "late");
 
   /* To be signaled by the compiler.  */
   DEFSYM (Qnative_compiler_error, "native-compiler-error");