* bug#25382: 25.1.91; easy-menu-add empty @ 2017-01-07 8:45 Andreas Röhler 2017-01-07 14:35 ` npostavs 0 siblings, 1 reply; 12+ messages in thread From: Andreas Röhler @ 2017-01-07 8:45 UTC (permalink / raw) To: 25382 GNU Emacs 25.1.91.1 (i686-pc-linux-gnu, GTK+ Version 3.14.5) of 2017-01-02 At python-mode.el `easy-menu-add' is used, which stopped working. Having a look at the source, looks like an empty body is provided. ^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#25382: 25.1.91; easy-menu-add empty 2017-01-07 8:45 bug#25382: 25.1.91; easy-menu-add empty Andreas Röhler @ 2017-01-07 14:35 ` npostavs 2017-01-09 6:40 ` Andreas Röhler 0 siblings, 1 reply; 12+ messages in thread From: npostavs @ 2017-01-07 14:35 UTC (permalink / raw) To: Andreas Röhler; +Cc: 25382 [-- Attachment #1: Type: text/plain, Size: 761 bytes --] found 25382 23.2 tags 25382 notabug quit Andreas Röhler <andreas.roehler@easy-emacs.de> writes: > GNU Emacs 25.1.91.1 (i686-pc-linux-gnu, GTK+ Version 3.14.5) of 2017-01-02 > > At python-mode.el `easy-menu-add' is used, which stopped > working. Having a look at the source, looks like an empty body is > provided. `easy-menu-add's body has been empty since at least 23.2, it was made empty by [1: 59c7bf4]. As far as I can tell, it only exists to be more compatible with XEmacs, so this is not a bug. 1: 2008-08-14 17:42:21 +0000 59c7bf4d7bf927e65c6cd40cf36e2e6bcbabfa78 (easy-menu-add): Don't precompute keybindings since those precomputed values aren't used any more. I propose the following patch for emacs-25 to clarify that: [-- Warning: decoded text below may be mangled, UTF-8 assumed --] [-- Attachment #2: patch --] [-- Type: text/x-diff, Size: 1919 bytes --] From 1a8caf7ad763aa03f279ec54ceec4ff9cc1d7237 Mon Sep 17 00:00:00 2001 From: Noam Postavsky <npostavs@gmail.com> Date: Sat, 7 Jan 2017 09:26:08 -0500 Subject: [PATCH v1] Clarify that easy-menu-add is a nop (Bug#25382) * lisp/emacs-lisp/easymenu.el (easy-menu-add): Make it into an alias of `ignore', like `easy-menu-remove'. --- lisp/emacs-lisp/easymenu.el | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/lisp/emacs-lisp/easymenu.el b/lisp/emacs-lisp/easymenu.el index 603bbcd..4fc9a78 100644 --- a/lisp/emacs-lisp/easymenu.el +++ b/lisp/emacs-lisp/easymenu.el @@ -489,7 +489,7 @@ easy-menu-change ;; XEmacs needs the following two functions to add and remove menus. ;; In Emacs this is done automatically when switching keymaps, so -;; here easy-menu-remove is a noop. +;; here easy-menu-remove and easy-menu-add are a noops. (defalias 'easy-menu-remove 'ignore "Remove MENU from the current menu bar. Contrary to XEmacs, this is a nop on Emacs since menus are automatically @@ -497,15 +497,16 @@ 'easy-menu-remove \(fn MENU)") -(defun easy-menu-add (_menu &optional _map) +(defalias 'easy-menu-add #'ignore "Add the menu to the menubar. -On Emacs, menus are already automatically activated when the -corresponding keymap is activated. On XEmacs this is needed to -actually add the menu to the current menubar. +On Emacs this is a nop, because menus are already automatically +activated when the corresponding keymap is activated. On XEmacs +this is needed to actually add the menu to the current menubar. You should call this once the menu and keybindings are set up -completely and menu filter functions can be expected to work." - ) +completely and menu filter functions can be expected to work. + +\(fn MENU &optional MAP)") (defun add-submenu (menu-path submenu &optional before in-menu) "Add submenu SUBMENU in the menu at MENU-PATH. -- 2.9.3 ^ permalink raw reply related [flat|nested] 12+ messages in thread
* bug#25382: 25.1.91; easy-menu-add empty 2017-01-07 14:35 ` npostavs @ 2017-01-09 6:40 ` Andreas Röhler 2017-01-10 4:40 ` npostavs 0 siblings, 1 reply; 12+ messages in thread From: Andreas Röhler @ 2017-01-09 6:40 UTC (permalink / raw) To: npostavs; +Cc: 25382 On 07.01.2017 15:35, npostavs@users.sourceforge.net wrote: > found 25382 23.2 > tags 25382 notabug > quit > > Andreas Röhler <andreas.roehler@easy-emacs.de> writes: > >> GNU Emacs 25.1.91.1 (i686-pc-linux-gnu, GTK+ Version 3.14.5) of 2017-01-02 >> >> At python-mode.el `easy-menu-add' is used, which stopped >> working. Having a look at the source, looks like an empty body is >> provided. > `easy-menu-add's body has been empty since at least 23.2, it was made > empty by [1: 59c7bf4]. As far as I can tell, it only exists to be more > compatible with XEmacs, so this is not a bug. > > 1: 2008-08-14 17:42:21 +0000 59c7bf4d7bf927e65c6cd40cf36e2e6bcbabfa78 > (easy-menu-add): Don't precompute keybindings since those precomputed values aren't used any more. > > I propose the following patch for emacs-25 to clarify that: > Looks redundant for me. Should one function "ignore" not be enough? ^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#25382: 25.1.91; easy-menu-add empty 2017-01-09 6:40 ` Andreas Röhler @ 2017-01-10 4:40 ` npostavs 2017-01-10 7:49 ` Andreas Röhler 0 siblings, 1 reply; 12+ messages in thread From: npostavs @ 2017-01-10 4:40 UTC (permalink / raw) To: Andreas Röhler; +Cc: 25382 Andreas Röhler <andreas.roehler@easy-emacs.de> writes: > > Looks redundant for me. Should one function "ignore" not be enough? It would seem less redundant if you maintained code that needed to work on both XEmacs and GNU Emacs. ^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#25382: 25.1.91; easy-menu-add empty 2017-01-10 4:40 ` npostavs @ 2017-01-10 7:49 ` Andreas Röhler 2017-01-10 13:23 ` npostavs 0 siblings, 1 reply; 12+ messages in thread From: Andreas Röhler @ 2017-01-10 7:49 UTC (permalink / raw) To: npostavs; +Cc: 25382 On 10.01.2017 05:40, npostavs@users.sourceforge.net wrote: > Andreas Röhler <andreas.roehler@easy-emacs.de> writes: >> Looks redundant for me. Should one function "ignore" not be enough? > It would seem less redundant if you maintained code that needed to work > on both XEmacs and GNU Emacs. Sorry , don't understand. If it's about compatibility, why not keep easy-menu-add adding the menu? ^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#25382: 25.1.91; easy-menu-add empty 2017-01-10 7:49 ` Andreas Röhler @ 2017-01-10 13:23 ` npostavs 2017-01-10 16:01 ` Andreas Röhler 0 siblings, 1 reply; 12+ messages in thread From: npostavs @ 2017-01-10 13:23 UTC (permalink / raw) To: Andreas Röhler; +Cc: 25382 Andreas Röhler <andreas.roehler@easy-emacs.de> writes: > On 10.01.2017 05:40, npostavs@users.sourceforge.net wrote: >> Andreas Röhler <andreas.roehler@easy-emacs.de> writes: >>> Looks redundant for me. Should one function "ignore" not be enough? >> It would seem less redundant if you maintained code that needed to work >> on both XEmacs and GNU Emacs. > > Sorry , don't understand. If it's about compatibility, why not keep > easy-menu-add adding the menu? As far as I can tell, it never did that in GNU Emacs. Why do you think it did? ^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#25382: 25.1.91; easy-menu-add empty 2017-01-10 13:23 ` npostavs @ 2017-01-10 16:01 ` Andreas Röhler 2017-01-10 16:21 ` Noam Postavsky 0 siblings, 1 reply; 12+ messages in thread From: Andreas Röhler @ 2017-01-10 16:01 UTC (permalink / raw) To: npostavs; +Cc: 25382 On 10.01.2017 14:23, npostavs@users.sourceforge.net wrote: > Andreas Röhler <andreas.roehler@easy-emacs.de> writes: > >> On 10.01.2017 05:40, npostavs@users.sourceforge.net wrote: >>> Andreas Röhler <andreas.roehler@easy-emacs.de> writes: >>>> Looks redundant for me. Should one function "ignore" not be enough? >>> It would seem less redundant if you maintained code that needed to work >>> on both XEmacs and GNU Emacs. >> Sorry , don't understand. If it's about compatibility, why not keep >> easy-menu-add adding the menu? > As far as I can tell, it never did that in GNU Emacs. Why do you think > it did? Because we used it following a conditional in python-mode.el. It got broken only recently. ^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#25382: 25.1.91; easy-menu-add empty 2017-01-10 16:01 ` Andreas Röhler @ 2017-01-10 16:21 ` Noam Postavsky 2017-01-10 18:47 ` Andreas Röhler 2017-01-11 18:24 ` Glenn Morris 0 siblings, 2 replies; 12+ messages in thread From: Noam Postavsky @ 2017-01-10 16:21 UTC (permalink / raw) To: Andreas Röhler; +Cc: 25382 On Tue, Jan 10, 2017 at 11:01 AM, Andreas Röhler <andreas.roehler@easy-emacs.de> wrote: > > >>> >>> Sorry , don't understand. If it's about compatibility, why not keep >>> easy-menu-add adding the menu? >> >> As far as I can tell, it never did that in GNU Emacs. Why do you think >> it did? > > > Because we used it following a conditional in python-mode.el. It got broken > only recently. > As I mentioned in https://debbugs.gnu.org/cgi/bugreport.cgi?bug=25382#8, it's been a nop since 2008. And even before that, it did not add any menus. Perhaps something else changed recently? ^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#25382: 25.1.91; easy-menu-add empty 2017-01-10 16:21 ` Noam Postavsky @ 2017-01-10 18:47 ` Andreas Röhler 2017-01-11 18:24 ` Glenn Morris 1 sibling, 0 replies; 12+ messages in thread From: Andreas Röhler @ 2017-01-10 18:47 UTC (permalink / raw) To: Noam Postavsky; +Cc: 25382 On 10.01.2017 17:21, Noam Postavsky wrote: > On Tue, Jan 10, 2017 at 11:01 AM, Andreas Röhler > <andreas.roehler@easy-emacs.de> wrote: >> >>>> Sorry , don't understand. If it's about compatibility, why not keep >>>> easy-menu-add adding the menu? >>> As far as I can tell, it never did that in GNU Emacs. Why do you think >>> it did? >> >> Because we used it following a conditional in python-mode.el. It got broken >> only recently. >> > As I mentioned in > https://debbugs.gnu.org/cgi/bugreport.cgi?bug=25382#8, it's been a nop > since 2008. And even before that, it did not add any menus. Perhaps > something else changed recently? That seems the case, thanks! ^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#25382: 25.1.91; easy-menu-add empty 2017-01-10 16:21 ` Noam Postavsky 2017-01-10 18:47 ` Andreas Röhler @ 2017-01-11 18:24 ` Glenn Morris 2017-01-12 7:38 ` Andreas Röhler 1 sibling, 1 reply; 12+ messages in thread From: Glenn Morris @ 2017-01-11 18:24 UTC (permalink / raw) To: Andreas Röhler, 25382; +Cc: Noam Postavsky Please give a minimal example starting from emacs -Q that shows what the problem actually is. http://xyproblem.info/ ^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#25382: 25.1.91; easy-menu-add empty 2017-01-11 18:24 ` Glenn Morris @ 2017-01-12 7:38 ` Andreas Röhler 2017-01-12 15:32 ` npostavs 0 siblings, 1 reply; 12+ messages in thread From: Andreas Röhler @ 2017-01-12 7:38 UTC (permalink / raw) To: Glenn Morris, 25382; +Cc: Noam Postavsky On 11.01.2017 19:24, Glenn Morris wrote: > Please give a minimal example starting from emacs -Q that shows what > the problem actually is. > > http://xyproblem.info/ Please see me previous post. That way `easy-menu-add' issues are supposed to be unrelated. ^ permalink raw reply [flat|nested] 12+ messages in thread
* bug#25382: 25.1.91; easy-menu-add empty 2017-01-12 7:38 ` Andreas Röhler @ 2017-01-12 15:32 ` npostavs 0 siblings, 0 replies; 12+ messages in thread From: npostavs @ 2017-01-12 15:32 UTC (permalink / raw) To: Andreas Röhler; +Cc: 25382 close 25382 quit Andreas Röhler <andreas.roehler@easy-emacs.de> writes: > On 11.01.2017 19:24, Glenn Morris wrote: >> Please give a minimal example starting from emacs -Q that shows what >> the problem actually is. >> >> http://xyproblem.info/ > > Please see me previous post. That way `easy-menu-add' issues are > supposed to be unrelated. Yeah, so if you find that the menu problems are from Emacs then open a new bug, because I've pushed my patch to emacs-25 [1: b0ade0d], and I'm closing this bug. 1: 2017-01-12 10:18:56 -0500 b0ade0df21d4cde8537c29f81eb10bdcf1cdfbfc Clarify that easy-menu-add is a nop (Bug#25382) ^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2017-01-12 15:32 UTC | newest] Thread overview: 12+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2017-01-07 8:45 bug#25382: 25.1.91; easy-menu-add empty Andreas Röhler 2017-01-07 14:35 ` npostavs 2017-01-09 6:40 ` Andreas Röhler 2017-01-10 4:40 ` npostavs 2017-01-10 7:49 ` Andreas Röhler 2017-01-10 13:23 ` npostavs 2017-01-10 16:01 ` Andreas Röhler 2017-01-10 16:21 ` Noam Postavsky 2017-01-10 18:47 ` Andreas Röhler 2017-01-11 18:24 ` Glenn Morris 2017-01-12 7:38 ` Andreas Röhler 2017-01-12 15:32 ` npostavs
Code repositories for project(s) associated with this external index https://git.savannah.gnu.org/cgit/emacs.git https://git.savannah.gnu.org/cgit/emacs/org-mode.git This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.