From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#11983: 24.1; Electric-command-loop broken? Date: Fri, 20 Jul 2012 05:47:40 -0400 Message-ID: References: <87pq7s6b8q.fsf@gnu.org> <20488.31825.986146.195944@gargle.gargle.HOWL> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1342777733 29276 80.91.229.3 (20 Jul 2012 09:48:53 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 20 Jul 2012 09:48:53 +0000 (UTC) Cc: 11983@debbugs.gnu.org To: "Roland Winkler" Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri Jul 20 11:48:53 2012 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 1Ss9pN-0002FK-7d for geb-bug-gnu-emacs@m.gmane.org; Fri, 20 Jul 2012 11:48:53 +0200 Original-Received: from localhost ([::1]:42458 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ss9pM-0003QR-C8 for geb-bug-gnu-emacs@m.gmane.org; Fri, 20 Jul 2012 05:48:52 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:53519) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ss9pG-0003Q7-VU for bug-gnu-emacs@gnu.org; Fri, 20 Jul 2012 05:48:50 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Ss9pF-0000JF-Rf for bug-gnu-emacs@gnu.org; Fri, 20 Jul 2012 05:48:46 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:42292) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ss9pF-0000JB-OZ for bug-gnu-emacs@gnu.org; Fri, 20 Jul 2012 05:48:45 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1Ss9vJ-00008i-Lb for bug-gnu-emacs@gnu.org; Fri, 20 Jul 2012 05:55:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 20 Jul 2012 09:55:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 11983 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 11983-submit@debbugs.gnu.org id=B11983.1342778044398 (code B ref 11983); Fri, 20 Jul 2012 09:55:01 +0000 Original-Received: (at 11983) by debbugs.gnu.org; 20 Jul 2012 09:54:04 +0000 Original-Received: from localhost ([127.0.0.1]:51835 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Ss9uO-00006L-73 for submit@debbugs.gnu.org; Fri, 20 Jul 2012 05:54:04 -0400 Original-Received: from pruche.dit.umontreal.ca ([132.204.246.22]:38786) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1Ss9uL-00005m-SZ for 11983@debbugs.gnu.org; Fri, 20 Jul 2012 05:54:02 -0400 Original-Received: from fmsmemgm.homelinux.net (lechon.iro.umontreal.ca [132.204.27.242]) by pruche.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id q6K9lgC0017809; Fri, 20 Jul 2012 05:47:43 -0400 Original-Received: by fmsmemgm.homelinux.net (Postfix, from userid 20848) id AA994AECB8; Fri, 20 Jul 2012 05:47:40 -0400 (EDT) In-Reply-To: <20488.31825.986146.195944@gargle.gargle.HOWL> (Roland Winkler's message of "Thu, 19 Jul 2012 16:29:53 -0500") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1.50 (gnu/linux) X-NAI-Spam-Flag: NO X-NAI-Spam-Threshold: 5 X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 1 Rules triggered RV4284=0 X-NAI-Spam-Version: 2.2.0.9309 : core <4284> : streams <787605> : uri <1170125> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.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:62182 Archived-At: > (unwind-protect > (catch 'return-tag > (Electric-command-loop 'return-tag)) > (cleanup-form)) But in which way is this different from `recursive-edit'? Hmmm... I guess it is different in that it is easier to exit an Electric-command-loop than a recursive-edit, so it is like a "transient/lightweight" recursive-edit. I think it would be good to try to describe it by comparing it to recursive-edit. It seems that it requires a fair bit of extra surrounding code to use it right. E.g. electric-buffer-list is buggy because it lacks this extra code: after popping up the electric-buffer-list, you can select some other window and work there, but the behavior is then all messed up. >> > - The doc string says >> > ;; Given third argument non-nil, it >> > ;; INHIBITS quitting unless the user types C-g at toplevel. This is >> > ;; so user can do things like C-u C-g and not get thrown out. >> > Yet it appears to me, that even for C-u C-g the user gets thrown out. >> >> I have no idea what this "C-u C-g" refers to, indeed. > If you type a plain C-g, Electric-command-loop throws > 'return-tag. Now the idea is that if you type C-u, then you > change your mind and want to cancel it by typing C-g, then the > code should not leave the temporary command loop. I see, yes. This inhibit-quitting seems dangerous since it binds inhibit-quit. But yes, I see in the code it tries to handle C-g after some prefix key. Not sure why it now fails or whether it ever worked. Stefan