diff options
Diffstat (limited to 'lisp/transient.el')
| -rw-r--r-- | lisp/transient.el | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/lisp/transient.el b/lisp/transient.el index cea49bb..c13cac2 100644 --- a/lisp/transient.el +++ b/lisp/transient.el @@ -3050,9 +3050,11 @@ value. Otherwise return CHILDREN as is.") (when (symbolp command) (remove-function (symbol-function command) advice)) (oset prefix unwind-suffix nil))))) - (add-function :around (if (symbolp this-command) - (symbol-function this-command) - this-command) + (add-function :around + (if (and (symbolp this-command) + (not (subrp (symbol-function this-command)))) + (symbol-function this-command) + this-command) advice '((depth . -99))) (cl-assert (>= emacs-major-version 30) nil @@ -3103,9 +3105,11 @@ value. Otherwise return CHILDREN as is.") (setq advice `(lambda (fn &rest args) (interactive ,advice-interactive) (apply ',advice-body fn args))) - (add-function :around (if (symbolp this-command) - (symbol-function this-command) - this-command) + (add-function :around + (if (and (symbolp this-command) + (not (subrp (symbol-function this-command)))) + (symbol-function this-command) + this-command) advice '((depth . -99)))))) (defun transient--premature-post-command () |
