]> git.eshelyaron.com Git - emacs.git/commitdiff
* lisp/emacs-lisp/nadvice.el (advice--add-function): Move func decl.
authorAndrea Corallo <acorallo@gnu.org>
Thu, 16 Nov 2023 08:03:20 +0000 (09:03 +0100)
committerAndrea Corallo <acorallo@gnu.org>
Thu, 16 Nov 2023 08:05:27 +0000 (09:05 +0100)
lisp/emacs-lisp/nadvice.el

index 98efb4c9c28e4f8fa1f5bbbbf9d3b3c55d6ffb18..6c5b11d2bd4b3af0b71a5641002da57098a54e19 100644 (file)
@@ -389,8 +389,6 @@ is also interactive.  There are 3 cases:
   `(advice--add-function ,how (gv-ref ,(advice--normalize-place place))
                          ,function ,props))
 
-(declare-function comp-subr-trampoline-install "comp-run")
-
 ;;;###autoload
 (defun advice--add-function (how ref function props)
   (when (and (featurep 'native-compile)
@@ -408,6 +406,7 @@ is also interactive.  There are 3 cases:
         ;; Must require explicitly as during bootstrap we have no
         ;; autoloads.
         (require 'comp-run)
+        (declare-function comp-subr-trampoline-install "comp-run")
         (comp-subr-trampoline-install subr-name))))
   (let* ((name (cdr (assq 'name props)))
          (a (advice--member-p (or name function) (if name t) (gv-deref ref))))