From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Michael Heerdegen Newsgroups: gmane.emacs.bugs Subject: bug#19853: Acknowledgement (25.0.50; ElDoc is displayed whether eldoc-mode is enabled or not) Date: Sun, 20 Mar 2016 20:53:55 +0100 Message-ID: <87k2kxkjsc.fsf@web.de> References: <864mqqgh3j.fsf@yandex.ru> <55AE4DA2.1060505@yandex.ru> <87wpoxko2a.fsf@web.de> <4b554a3b-bc21-859e-4cfc-3c82901ea32f@yandex.ru> <87shzlkngx.fsf@web.de> <7be513e7-2d38-1e78-46f6-03ca17d58f90@yandex.ru> <87oaa9klc5.fsf@web.de> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1458503727 9566 80.91.229.3 (20 Mar 2016 19:55:27 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 20 Mar 2016 19:55:27 +0000 (UTC) Cc: 19853@debbugs.gnu.org To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Mar 20 20:55:11 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ahjRN-0003jU-2u for geb-bug-gnu-emacs@m.gmane.org; Sun, 20 Mar 2016 20:55:09 +0100 Original-Received: from localhost ([::1]:54296 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahjRM-0002Qy-ES for geb-bug-gnu-emacs@m.gmane.org; Sun, 20 Mar 2016 15:55:08 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54782) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahjRJ-0002PO-77 for bug-gnu-emacs@gnu.org; Sun, 20 Mar 2016 15:55:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ahjRG-0007N5-0n for bug-gnu-emacs@gnu.org; Sun, 20 Mar 2016 15:55:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:58755) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ahjRF-0007N0-TE for bug-gnu-emacs@gnu.org; Sun, 20 Mar 2016 15:55:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ahjRF-0004YF-LG for bug-gnu-emacs@gnu.org; Sun, 20 Mar 2016 15:55:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Michael Heerdegen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 20 Mar 2016 19:55:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 19853 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 19853-submit@debbugs.gnu.org id=B19853.145850364517425 (code B ref 19853); Sun, 20 Mar 2016 19:55:01 +0000 Original-Received: (at 19853) by debbugs.gnu.org; 20 Mar 2016 19:54:05 +0000 Original-Received: from localhost ([127.0.0.1]:55880 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ahjQL-0004Wz-9I for submit@debbugs.gnu.org; Sun, 20 Mar 2016 15:54:05 -0400 Original-Received: from mout.web.de ([212.227.15.4]:64727) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ahjQJ-0004W1-FZ for 19853@debbugs.gnu.org; Sun, 20 Mar 2016 15:54:03 -0400 Original-Received: from drachen.dragon ([94.218.210.27]) by smtp.web.de (mrweb004) with ESMTPSA (Nemesis) id 0MgIMg-1aSn230Ses-00NioE; Sun, 20 Mar 2016 20:53:57 +0100 In-Reply-To: (Dmitry Gutov's message of "Sun, 20 Mar 2016 21:27:09 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs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gI1ocSTi5oOsJtAGLZiTTPGuGFX X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:115179 Archived-At: Dmitry Gutov writes: > On 03/20/2016 09:20 PM, Michael Heerdegen wrote: > > > Turning on the globalized local hook would not have an immediate effect > > on the affected buffers I think. > > Not sure what you mean. Globalized local hook? > > If globalized mode was off, and you turn it on, it turns on the local > mode in all relevant buffers, right away. > > Just try it with e.g. global-font-lock-mode. Yes, correct. I only overflew the sources and missed that part - my mistake. > > That's a valid point, the current implementation doesn't cover this > > case. I think > > > > (setq-local global-eldoc-mode nil) > > > > should work, but it looks weird, and it should not be necessary to > > modify a variable after we already have two modes. > > Yes, it looks silly, and might even break some expectations of the > minor mode machinery. If we want the global mode to push its stuff into the global hook bindings, and not into all the local hook bindings in every single buffer where the mode is applicable - can we achieve this with `define-globalized-minor-mode'? It doesn't seem so: `define-globalized-minor-mode' doesn't accept any kind of BODY argument. I think this is the cause of why the author reinvented it, and that in a not fully compliant way. Eldoc is not the only mode where this problem arises. In general, it can be beneficial to add to the global hook bindings: when a buffer is affected by the global hook, but it is not current, the local hook bindings are not run. Sometimes this is useful (I can give an example if you want). But in this case, I think it is not. So I tend to agree with you: simply globalizing eldoc-mode would be better, if we don't miss anything. And then, I think making `define-globalized-minor-mode' accept a BODY argument would be good - a globalized minor mode might want to do some global setup. Michael.