From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Stephen J. Turnbull" Newsgroups: gmane.emacs.devel Subject: Re: Random idea: Debugging `quit' Date: Mon, 12 Sep 2011 08:28:18 +0900 Message-ID: <87ty8ipskt.fsf@uwakimon.sk.tsukuba.ac.jp> References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1315783717 21594 80.91.229.12 (11 Sep 2011 23:28:37 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 11 Sep 2011 23:28:37 +0000 (UTC) Cc: Andreas Schwab , emacs-devel@gnu.org To: Lars Magne Ingebrigtsen Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Sep 12 01:28:33 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1R2tRu-00079u-Sb for ged-emacs-devel@m.gmane.org; Mon, 12 Sep 2011 01:28:31 +0200 Original-Received: from localhost ([::1]:35641 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R2tRu-0003H4-Ev for ged-emacs-devel@m.gmane.org; Sun, 11 Sep 2011 19:28:30 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:50277) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R2tRr-0003Go-8p for emacs-devel@gnu.org; Sun, 11 Sep 2011 19:28:28 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R2tRq-0006gz-AI for emacs-devel@gnu.org; Sun, 11 Sep 2011 19:28:27 -0400 Original-Received: from mgmt2.sk.tsukuba.ac.jp ([130.158.97.224]:48454) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R2tRq-0006fy-2L for emacs-devel@gnu.org; Sun, 11 Sep 2011 19:28:26 -0400 Original-Received: from uwakimon.sk.tsukuba.ac.jp (uwakimon.sk.tsukuba.ac.jp [130.158.99.156]) by mgmt2.sk.tsukuba.ac.jp (Postfix) with ESMTP id 9551C9707A1; Mon, 12 Sep 2011 08:28:18 +0900 (JST) Original-Received: by uwakimon.sk.tsukuba.ac.jp (Postfix, from userid 1000) id 8F3E91A278D; Mon, 12 Sep 2011 08:28:18 +0900 (JST) In-Reply-To: X-Mailer: VM undefined under 21.5 (beta31) "ginger" 3bc58dc9d688 XEmacs Lucid (x86_64-unknown-linux) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 130.158.97.224 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:143906 Archived-At: Lars Magne Ingebrigtsen writes: > Yes, but could the `C-g' handler then check the prefix, and see whether > anything is in there? I'm assuming that Emacs would know at that point > (since it's already parsed its way to the `C-g' in the input stream), > which may be a totally wrong assumption, of course. :-) It is a wrong assumption for XEmacs, at least. XEmacs checks the incoming event for C-g at the time of queueing the event for later processing by XEmacs. The only "parsing" of events at that level is into "quit events" and "non-quit events". I suspect Emacs does the same. In theory one could force parsing of the queue, somehow disabling "undesirable" actions, but this would be fragile since commands in the queue could install keymaps etc which changes the interpretation of the event stream.