From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Bruno BARBIER Newsgroups: gmane.emacs.bugs Subject: bug#22272: 24.5; nonfunctional Emacs with a bad global mode (post-command-hook). Date: Thu, 31 Dec 2015 07:40:19 +0100 Message-ID: <20151231073819brubar.cs@gmail.com> References: <87fuykxunv.fsf@tosh-laptop.i-did-not-set--mail-host-address--so-tickle-me> <83ziwrbynr.fsf@gnu.org> <20151230194329brubar.cs@gmail.com> <87lh8b65qo.fsf@web.de> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1451544092 2388 80.91.229.3 (31 Dec 2015 06:41:32 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 31 Dec 2015 06:41:32 +0000 (UTC) Cc: 22272@debbugs.gnu.org To: Michael Heerdegen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Thu Dec 31 07:41:15 2015 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 1aEWvB-00039G-N7 for geb-bug-gnu-emacs@m.gmane.org; Thu, 31 Dec 2015 07:41:13 +0100 Original-Received: from localhost ([::1]:54832 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aEWv7-0000u0-Sl for geb-bug-gnu-emacs@m.gmane.org; Thu, 31 Dec 2015 01:41:09 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:55265) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aEWv3-0000tt-RB for bug-gnu-emacs@gnu.org; Thu, 31 Dec 2015 01:41:06 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aEWv0-0004Cg-LU for bug-gnu-emacs@gnu.org; Thu, 31 Dec 2015 01:41:05 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:43262) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aEWv0-0004CR-Hv for bug-gnu-emacs@gnu.org; Thu, 31 Dec 2015 01:41:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84) (envelope-from ) id 1aEWv0-0001zn-D2 for bug-gnu-emacs@gnu.org; Thu, 31 Dec 2015 01:41:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Bruno BARBIER Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 31 Dec 2015 06:41:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 22272 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 22272-submit@debbugs.gnu.org id=B22272.14515440527648 (code B ref 22272); Thu, 31 Dec 2015 06:41:02 +0000 Original-Received: (at 22272) by debbugs.gnu.org; 31 Dec 2015 06:40:52 +0000 Original-Received: from localhost ([127.0.0.1]:50864 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aEWup-0001zI-W8 for submit@debbugs.gnu.org; Thu, 31 Dec 2015 01:40:52 -0500 Original-Received: from mail-wm0-f43.google.com ([74.125.82.43]:34813) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aEWun-0001z3-UY for 22272@debbugs.gnu.org; Thu, 31 Dec 2015 01:40:50 -0500 Original-Received: by mail-wm0-f43.google.com with SMTP id u188so58303844wmu.1 for <22272@debbugs.gnu.org>; Wed, 30 Dec 2015 22:40:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; bh=YFpQxDaeDIpjtbllh14gZ+jN3mPtBomaL9TXqH3ERZk=; b=krV+pThkV1zloU1356kJckzGoAPjEa3+7brKll/qYgfF7QY4zhlQyskQsCXbKEhJXM oMl7JMHSGFiKUdL/ppMldUm94ObnONwQQMAgAbZVNNzLuGwVFAnJ3D24m9fK8CpFhdWS ArE/OSgU6o686kJsVF7NrUbhNjNyMxTxspMXD7ktJgnm7tGYK9U8fkjaGBxE/u0+HpJs xXQAxEq34ZzHacTZYtZDeSyJ318hnICUFeIx8nw1ExFHHOt97yXn4bPsEGGIKmcmfqtD ckFKUsBwjeSEMsAdMsTllflTeqdZqDNPIl7cyzfA1laAoL5ZaGlMj13kkyRHO3vmPAoI ygcg== X-Received: by 10.194.80.65 with SMTP id p1mr42148794wjx.152.1451544044372; Wed, 30 Dec 2015 22:40:44 -0800 (PST) Original-Received: from gmail.com (sta21-6-78-240-71-23.fbx.proxad.net. [78.240.71.23]) by smtp.gmail.com with ESMTPSA id l7sm68353435wjx.14.2015.12.30.22.40.41 (version=TLS1 cipher=AES128-SHA bits=128/128); Wed, 30 Dec 2015 22:40:43 -0800 (PST) Original-Received: by gmail.com (nbSMTP-1.00) for uid 1000 (using TLSv1/SSLv3 with cipher AES128-SHA (128/128 bits)) brubar.cs@gmail.com; Thu, 31 Dec 2015 07:40:25 +0100 (CET) Content-Disposition: inline In-Reply-To: <87lh8b65qo.fsf@web.de> User-Agent: Mutt/1.5.21 (2010-09-15) 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:111059 Archived-At: On Wed, Dec 30, 2015 at 09:28:31PM +0100, Michael Heerdegen wrote: > Bruno BARBIER writes: > > > 1. the error is not silenced, > > > > 2. and the function is not removed. > > > > Thus, the error is constantly raised rendering Emacs > > nonfunctional. That's why I had to ask the OS to kill my Emacs. > > > > So, I'm saying Emacs could be slightly improved by following what the > > documentation says. > > > > Am I wrong ? > > Emacs behaves as documented, but the situation is more complicated as > you expect - See the code `define-globalized-minor-mode': > > Turning on a globalized minor mode pushes a function to > change-major-mode-hook that adds a function to post-command-hook - and > that's the one that fails. So the cited behavior of Emacs removing the > erroneous function from post-command-hook doesn't solve the problem > permanently. Ok. I see. Not that simple indeed and I was wrong: the error is silenced and the function removed (but `change-major-mode-hook' pushes it back into `post-command-hook' as instructed by `define-globalized-minor-mode'). The simplest solution is probably to use a spare Emacs when developping a new global mode and to catch errors in it; that makes sense. I guess this non bug should be closed. Sorry for the noise. Thanks Eli and Michael for your prompt reply and your time. Bruno. > > Michael. >