From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: David Kastrup Newsgroups: gmane.emacs.devel Subject: Re: [PATCH] ; Do not overwrite prexisting contents of unread-command-events Date: Mon, 03 Aug 2015 16:58:07 +0200 Message-ID: <87d1z45shs.fsf@fencepost.gnu.org> References: <1437843433-4931-1-git-send-email-dak@gnu.org> <878ua4kvxd.fsf@fencepost.gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1438613908 6999 80.91.229.3 (3 Aug 2015 14:58:28 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 3 Aug 2015 14:58:28 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Aug 03 16:58:27 2015 Return-path: Envelope-to: ged-emacs-devel@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 1ZMHC7-0004qs-5x for ged-emacs-devel@m.gmane.org; Mon, 03 Aug 2015 16:58:27 +0200 Original-Received: from localhost ([::1]:59495 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMHC6-0004NL-KZ for ged-emacs-devel@m.gmane.org; Mon, 03 Aug 2015 10:58:26 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:38261) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMHBq-0004NG-Uy for emacs-devel@gnu.org; Mon, 03 Aug 2015 10:58:11 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZMHBp-0004Oz-Od for emacs-devel@gnu.org; Mon, 03 Aug 2015 10:58:10 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:45956) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMHBp-0004Og-Kp for emacs-devel@gnu.org; Mon, 03 Aug 2015 10:58:09 -0400 Original-Received: from localhost ([127.0.0.1]:59771 helo=lola) by fencepost.gnu.org with esmtp (Exim 4.82) (envelope-from ) id 1ZMHBo-0007C8-W4 for emacs-devel@gnu.org; Mon, 03 Aug 2015 10:58:09 -0400 Original-Received: by lola (Postfix, from userid 1000) id EB697DF388; Mon, 3 Aug 2015 16:58:07 +0200 (CEST) In-Reply-To: <878ua4kvxd.fsf@fencepost.gnu.org> (David Kastrup's message of "Sat, 25 Jul 2015 19:07:42 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::e 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:188341 Archived-At: David Kastrup writes: > Unfortunately, recording macros with C-x ( ... C-x ) and replaying with > C-x e is still bleeding probably something like 15% of my events > synthesized from Midi when pressing chord buttons on an accordion > (3=A0immediately adjacent Midi events taking something like 2 bytes each > at 31250 bits/s, read in via an Emacs process filter function). > > So the output of C-x e is somewhat shorter than the equivalent when > recording. > > I suspect that code of the form > > (let (unread-command-events) > ... > ) > > in the macro recording is at fault by letting material arrive in a > let-bound unread-command-events and not taking all of it out before > unbinding. > > But at least most of the other opportunities for dropping > events/characters are addressed by this patch. Barring any comments, I am going to push this patch to master, probably by tomorrow. It does not fix the main lossage of events pushed into unread-command-events (which is likely the fault of some code in src/keyboard.c and also keeps the events from appearing in a dribble file even though their keymap actions are executed). But it reduces the amount of stuff one has to worry about. --=20 David Kastrup