branch: externals/transient
commit dd970cd464570c85ca3492706b6239029876556d
Author: Jonas Bernoulli <jo...@bernoul.li>
Commit: Jonas Bernoulli <jo...@bernoul.li>

    Compile suffix commands that are defined inside prefix definitions
    
    Closes #256.
---
 lisp/transient.el | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/lisp/transient.el b/lisp/transient.el
index a61179f277..67bcefd04b 100644
--- a/lisp/transient.el
+++ b/lisp/transient.el
@@ -1088,7 +1088,10 @@ example, sets a variable, use `transient-define-infix' 
instead.
                       `(prog1 ',sym
                          (put ',sym 'interactive-only t)
                          (put ',sym 'command-modes (list 'not-a-mode))
-                         (defalias ',sym ,(macroexp-quote cmd)))))))
+                         (defalias ',sym
+                           ,(if (eq (car-safe cmd) 'lambda)
+                                cmd
+                              (macroexp-quote cmd))))))))
        ((or (stringp car)
             (and car (listp car)))
         (let ((arg pop)

Reply via email to