From debbugs-submit-bounces@debbugs.gnu.org Sun Apr 19 07:12:42 2020 Received: (at submit) by debbugs.gnu.org; 19 Apr 2020 11:12:42 +0000 Received: from localhost ([127.0.0.1]:44142 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jQ7sQ-0000vj-Fj for submit@debbugs.gnu.org; Sun, 19 Apr 2020 07:12:42 -0400 Received: from lists.gnu.org ([209.51.188.17]:37243) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jQ7sP-0000vc-6z for submit@debbugs.gnu.org; Sun, 19 Apr 2020 07:12:41 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:36148) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jQ7sO-0000sH-So for bug-gnu-emacs@gnu.org; Sun, 19 Apr 2020 07:12:41 -0400 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-0.0 required=5.0 tests=SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.90_1) (envelope-from ) id 1jQ7sO-0003JI-1Q for bug-gnu-emacs@gnu.org; Sun, 19 Apr 2020 07:12:40 -0400 Received: from colin.muc.de ([193.149.48.1]:45862 helo=mail.muc.de) by eggs.gnu.org with smtp (Exim 4.90_1) (envelope-from ) id 1jQ7sN-0003GT-Av for bug-gnu-emacs@gnu.org; Sun, 19 Apr 2020 07:12:39 -0400 Received: (qmail 87807 invoked by uid 3782); 19 Apr 2020 11:12:34 -0000 Received: from acm.muc.de (p4FE151BB.dip0.t-ipconnect.de [79.225.81.187]) by localhost.muc.de (tmda-ofmipd) with ESMTP; Sun, 19 Apr 2020 13:12:33 +0200 Received: (qmail 22082 invoked by uid 1000); 19 Apr 2020 11:12:33 -0000 Date: Sun, 19 Apr 2020 11:12:33 +0000 To: bug-gnu-emacs@gnu.org Subject: Reinitialising the major mode disables which-function-mode. Message-ID: <20200419111233.GA22022@ACM> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline X-Delivery-Agent: TMDA/1.1.12 (Macallan) From: Alan Mackenzie X-Primary-Address: acm@muc.de Received-SPF: pass client-ip=193.149.48.1; envelope-from=acm@muc.de; helo=mail.muc.de X-detected-operating-system: by eggs.gnu.org: FreeBSD 9.x or newer [fuzzy] X-Received-From: 193.149.48.1 X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hello, Emacs. In a typical buffer, say an emacs-lisp-mode buffer, with which-function-mode enabled and working, do M-x emacs-lisp-mode . which-function-mode is no longer working. ######################################################################### The cause of this is that the enablement of w-f-m is stored in a buffer local variable which-func-mode. This local variable gets killed on reinitialising the major mode. There is nothing to set it to non-nil again. When visiting a file, which-func-mode gets set in a file-find-hook function called which-func-ff-hook. Suggested fix: Move which-func-ff-hook to after-change-major-mode-hook (renaming it, of course). -- Alan Mackenzie (Nuremberg, Germany). From debbugs-submit-bounces@debbugs.gnu.org Wed May 20 14:08:47 2020 Received: (at 40714-done) by debbugs.gnu.org; 20 May 2020 18:08:47 +0000 Received: from localhost ([127.0.0.1]:54226 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jbT94-0004Vv-PU for submit@debbugs.gnu.org; Wed, 20 May 2020 14:08:46 -0400 Received: from colin.muc.de ([193.149.48.1]:45036 helo=mail.muc.de) by debbugs.gnu.org with smtp (Exim 4.84_2) (envelope-from ) id 1jbT92-0004Vl-Eo for 40714-done@debbugs.gnu.org; Wed, 20 May 2020 14:08:44 -0400 Received: (qmail 6894 invoked by uid 3782); 20 May 2020 18:08:42 -0000 Received: from acm.muc.de (p4fe15b23.dip0.t-ipconnect.de [79.225.91.35]) by localhost.muc.de (tmda-ofmipd) with ESMTP; Wed, 20 May 2020 20:08:42 +0200 Received: (qmail 19740 invoked by uid 1000); 20 May 2020 18:08:42 -0000 Date: Wed, 20 May 2020 18:08:42 +0000 To: 40714-done@debbugs.gnu.org Subject: Re: bug#40714: Acknowledgement (Reinitialising the major mode disables which-function-mode.) Message-ID: <20200520180842.GA19724@ACM> References: <20200419111233.GA22022@ACM> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Delivery-Agent: TMDA/1.1.12 (Macallan) From: Alan Mackenzie X-Primary-Address: acm@muc.de X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 40714-done X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Bug fixed in master. -- Alan Mackenzie (Nuremberg, Germany). From unknown Fri Jun 20 18:24:49 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Thu, 18 Jun 2020 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator