emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

master a070bd1: * lisp/emacs-lisp/easymenu.el: Don't quote lambdas


From: Stefan Monnier
Subject: master a070bd1: * lisp/emacs-lisp/easymenu.el: Don't quote lambdas
Date: Thu, 7 Nov 2019 17:09:21 -0500 (EST)

branch: master
commit a070bd1c8b5213ad469d41dd80d392f924644aed
Author: Stefan Monnier <address@hidden>
Commit: Stefan Monnier <address@hidden>

    * lisp/emacs-lisp/easymenu.el: Don't quote lambdas
    
    (easy-menu-do-define, easy-menu-make-symbol): Replace `(lambda ..)
    with a closure.
---
 lisp/emacs-lisp/easymenu.el | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/lisp/emacs-lisp/easymenu.el b/lisp/emacs-lisp/easymenu.el
index f274f62..292d50b 100644
--- a/lisp/emacs-lisp/easymenu.el
+++ b/lisp/emacs-lisp/easymenu.el
@@ -183,17 +183,17 @@ This is expected to be bound to a mouse event."
     (when symbol
       (set symbol keymap)
       (defalias symbol
-       `(lambda (event) ,doc (interactive "@e")
+       (lambda (event) (:documentation doc) (interactive "@e")
           ;; FIXME: XEmacs uses popup-menu which calls the binding
           ;; while x-popup-menu only returns the selection.
           (x-popup-menu event
-                        (or (and (symbolp ,symbol)
+                        (or (and (symbolp symbol)
                                  (funcall
-                                  (or (plist-get (get ,symbol 'menu-prop)
+                                  (or (plist-get (get symbol 'menu-prop)
                                                  :filter)
                                       'identity)
-                                  (symbol-function ,symbol)))
-                            ,symbol)))))
+                                  (symbol-function symbol)))
+                            symbol)))))
     (dolist (map (if (keymapp maps) (list maps) maps))
       (define-key map
         (vector 'menu-bar (easy-menu-intern (car menu)))
@@ -475,7 +475,7 @@ When non-nil, NOEXP indicates that CALLBACK cannot be an 
expression
                   ;; `functionp' is probably not needed.
                   (functionp callback) noexp)
               callback
-           `(lambda () (interactive) ,callback)))
+           (lambda () (interactive) callback)))
     command))
 
 ;;;###autoload



reply via email to

[Prev in Thread] Current Thread [Next in Thread]