From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Sho Takemori Newsgroups: gmane.emacs.bugs Subject: bug#22674: 25.0.91; recent-keys returns a vector containing events generated by keyboard macros Date: Mon, 15 Feb 2016 15:45:53 +0900 Message-ID: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001a11403bf243adbe052bc95e11 X-Trace: ger.gmane.org 1455518841 17852 80.91.229.3 (15 Feb 2016 06:47:21 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 15 Feb 2016 06:47:21 +0000 (UTC) To: 22674@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Feb 15 07:47:11 2016 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 1aVCw9-0000XV-Vj for geb-bug-gnu-emacs@m.gmane.org; Mon, 15 Feb 2016 07:47:10 +0100 Original-Received: from localhost ([::1]:57109 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aVCw9-0004W0-4J for geb-bug-gnu-emacs@m.gmane.org; Mon, 15 Feb 2016 01:47:09 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56090) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aVCw4-0004Vj-8Y for bug-gnu-emacs@gnu.org; Mon, 15 Feb 2016 01:47:05 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aVCw2-0007MW-Qx for bug-gnu-emacs@gnu.org; Mon, 15 Feb 2016 01:47:04 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:48507) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aVCw2-0007MS-ND for bug-gnu-emacs@gnu.org; Mon, 15 Feb 2016 01:47:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84) (envelope-from ) id 1aVCw2-0001F3-GH for bug-gnu-emacs@gnu.org; Mon, 15 Feb 2016 01:47:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Sho Takemori Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 15 Feb 2016 06:47:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 22674 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.14555187674703 (code B ref -1); Mon, 15 Feb 2016 06:47:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 15 Feb 2016 06:46:07 +0000 Original-Received: from localhost ([127.0.0.1]:39282 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aVCv9-0001Dn-AG for submit@debbugs.gnu.org; Mon, 15 Feb 2016 01:46:07 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:36796) by debbugs.gnu.org with esmtp (Exim 4.84) (envelope-from ) id 1aVCv6-0001D2-QQ for submit@debbugs.gnu.org; Mon, 15 Feb 2016 01:46:05 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aVCv0-000703-4i for submit@debbugs.gnu.org; Mon, 15 Feb 2016 01:45:59 -0500 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:35447) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aVCv0-0006zs-0j for submit@debbugs.gnu.org; Mon, 15 Feb 2016 01:45:58 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56000) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aVCuy-0004Oa-JN for bug-gnu-emacs@gnu.org; Mon, 15 Feb 2016 01:45:57 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aVCux-0006wU-2M for bug-gnu-emacs@gnu.org; Mon, 15 Feb 2016 01:45:56 -0500 Original-Received: from mail-lf0-x22f.google.com ([2a00:1450:4010:c07::22f]:36425) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aVCuw-0006vd-Kf for bug-gnu-emacs@gnu.org; Mon, 15 Feb 2016 01:45:54 -0500 Original-Received: by mail-lf0-x22f.google.com with SMTP id 78so82876806lfy.3 for ; Sun, 14 Feb 2016 22:45:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=kIQFSp6Ddwio7A1TW4Qv1EDLJSgNbh6GDcAdnSzuGpI=; b=hiZqXDS4AGqTSa4xTK7lcjxHYXoaCfBMVRq5XG6i5jGjjW2d+v89nNIR0SeGavo6YA O3JSdPt7aY3q/kopHtGnB6T7eo1Pfty6HhUYSZmrJV+bi+wVmw7cpxDS/jmxyraN+vGG NTWfiKtVVusAEbPyuILI5xt6WjN5HOER/1QzXOQYf4GPurcSJ9YUWEeynMhHvl8/SvRq j5jutnq0Ld7ua90BtowSGmrFZM4+7Ke61mlpNeQ1fEiPVRU5QDTp5Iy3dptREA4pUk4j AYpnXNehyEJSgze2KYtb1MGRFhqsnJsCzqjzHEyUmFLqlqueSsljvA1g+1FDdMi3r+qO 2S0g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:date:message-id:subject:from:to :content-type; bh=kIQFSp6Ddwio7A1TW4Qv1EDLJSgNbh6GDcAdnSzuGpI=; b=hPzTSUfH1hwfvSrFG6MMhrDoeyWnYobLVogwxAKTi327dh6bePpH1WaWKCi2US+SDJ DBj6iJ2SDxokQiz/LOcBjebKJHaGTLy0Fdi2/cUBEut974xCU3SG93ucEvYdwCrX0TlD xzGvjPquRZxVlPei4+2qW0jYFVIdIS7kqzbom03fKkBEHj9vdGTjcR3UAqwWg0zmIzqT 329hjYNzm/6iUA56DDa3Ot0tMqucraed0MQ2CMfhjphQkZJW5o/kW2Vmevfg3OHmx1dl 7FrW0nw+PCaFmFWyUB0N/HCUGkjy5DE1aSnLfPFrxnLn9RVt+kYleuyxI62FB8N8pLZ3 to0g== X-Gm-Message-State: AG10YOR8n3WPMrACv9yOgqzUk34heVG5+abHeTPZOJ0bj8m0rQ+d3SPoULUTlSfHjcgfQ5xP47fsIr9uv3nIgg== X-Received: by 10.25.31.193 with SMTP id f184mr6115158lff.5.1455518753465; Sun, 14 Feb 2016 22:45:53 -0800 (PST) Original-Received: by 10.112.207.227 with HTTP; Sun, 14 Feb 2016 22:45:53 -0800 (PST) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x 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:113056 Archived-At: --001a11403bf243adbe052bc95e11 Content-Type: text/plain; charset=UTF-8 According to the document of `recent-keys`, the return value does not contain events generated by keyboard macros, but it does. To reproduce this: Run Emacs by "emacs -Q", define a keyboard macro by " a " (a keyboard macro that inserts "a"), and hit twice. I expected the last two items of the return value of recent-keys are F4, F4, but they are F4, 97. I used the following code to check it. (progn (require 'cl-lib) (defun my/test-recent-keys () (message (prin1-to-string (let ((kys (recent-keys))) (cl-subseq kys (- (length kys) 2)))))) (add-hook 'post-command-hook #'my/test-recent-keys)) In Emacs 24.5, the last two items are F4, F4 as expected. Sho Takemori In GNU Emacs 25.0.91.1 (x86_64-unknown-linux-gnu, GTK+ Version 3.16.7) of 2016-02-15 built on XPS-13 Repository revision: f3aaca3552ba961d13cd1ee935c1c6b075f2398a Windowing system distributor 'The X.Org Foundation', version 11.0.11702000 System Description: Ubuntu 15.10 Configured features: XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND GPM DBUS GCONF GSETTINGS NOTIFY ACL LIBSELINUX GNUTLS LIBXML2 FREETYPE M17N_FLT LIBOTF XFT ZLIB TOOLKIT_SCROLL_BARS GTK3 X11 Important settings: value of $LC_MONETARY: ja_JP.UTF-8 value of $LC_NUMERIC: ja_JP.UTF-8 value of $LC_TIME: ja_JP.UTF-8 value of $LANG: ja_JP.UTF-8 value of $XMODIFIERS: @im=ibus locale-coding-system: utf-8-unix Major mode: Lisp Interaction Minor modes in effect: tooltip-mode: t global-eldoc-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Recent messages: [backspace 67108911 backspace backspace backspace] [67108911 backspace backspace backspace 114] [backspace backspace backspace 114 101] [backspace backspace 114 101 109] [backspace 114 101 109 111] [114 101 109 111 118] [101 109 111 118 101] [109 111 118 101 5] (eldoc-schedule-timer) funcall-interactively: End of buffer [4 times] Load-path shadows: None found. Features: (shadow sort mail-extr emacsbug message dired format-spec rfc822 mml mml-sec epg epg-config gnus-util mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util help-fns mail-prsvr mail-utils kmacro cl-extra help-mode easymenu cl-loaddefs pcase cl-lib time-date mule-util japan-util tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type mwheel x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list newcomment elisp-mode lisp-mode prog-mode register page menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core frame cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese charscript case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer cl-preloaded nadvice loaddefs button faces cus-face macroexp files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote dbusbind inotify dynamic-setting system-font-setting font-render-setting move-toolbar gtk x-toolkit x multi-tty make-network-process emacs) Memory information: ((conses 16 92247 8518) (symbols 48 20094 0) (miscs 40 474 146) (strings 32 15372 4220) (string-bytes 1 449613) (vectors 16 12977) (vector-slots 8 514251 7318) (floats 8 166 121) (intervals 56 223 10) (buffers 976 11) (heap 1024 40476 865)) --001a11403bf243adbe052bc95e11 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
According to the document of `recent-keys`, the retur= n value does not contain
events generated by keyboard macros, but= it does.

To reproduce this:
Run Emacs b= y "emacs -Q",
define a keyboard macro by "<F3&g= t; a <F4>" (a keyboard macro that inserts "a"),
<= div>and hit <F4> twice.
I expected the last two items of th= e return value of recent-keys are F4, F4,
but they are F4, 97.

I used the following code to check it.
(progn
=C2=A0 (require 'cl-lib)
=C2=A0 = (defun my/test-recent-keys ()
=C2=A0 =C2=A0 (message (prin1-to-st= ring
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (let ((kys = (recent-keys)))
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 (cl-subseq kys (- (length kys) 2))))))
=C2=A0 (add-hook &#= 39;post-command-hook #'my/test-recent-keys))

I= n Emacs 24.5, the last two items are F4, F4 as expected.

Sho Takemori

In GNU Emacs 25.0.91.1 (x86_64= -unknown-linux-gnu, GTK+ Version 3.16.7)
=C2=A0of 2016-02-15 buil= t on XPS-13
Repository revision: f3aaca3552ba961d13cd1ee935c1c6b0= 75f2398a
Windowing system distributor 'The X.Org Foundation&#= 39;, version 11.0.11702000
System Description: Ubuntu 15.10

Confi= gured features:
XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND GPM = DBUS GCONF GSETTINGS
NOTIFY ACL LIBSELINUX GNUTLS LIBXML2 FREETYP= E M17N_FLT LIBOTF XFT ZLIB
TOOLKIT_SCROLL_BARS GTK3 X11

Important settings:
=C2=A0 value of $LC_MONETARY:= ja_JP.UTF-8
=C2=A0 value of $LC_NUMERIC: ja_JP.UTF-8
= =C2=A0 value of $LC_TIME: ja_JP.UTF-8
=C2=A0 value of $LANG: ja_J= P.UTF-8
=C2=A0 value of $XMODIFIERS: @im=3Dibus
=C2=A0 = locale-coding-system: utf-8-unix

Major mode: Lisp = Interaction

Minor modes in effect:
=C2= =A0 tooltip-mode: t
=C2=A0 global-eldoc-mode: t
=C2=A0 = electric-indent-mode: t
=C2=A0 mouse-wheel-mode: t
=C2= =A0 tool-bar-mode: t
=C2=A0 menu-bar-mode: t
=C2=A0 fil= e-name-shadow-mode: t
=C2=A0 global-font-lock-mode: t
= =C2=A0 font-lock-mode: t
=C2=A0 blink-cursor-mode: t
= =C2=A0 auto-composition-mode: t
=C2=A0 auto-encryption-mode: t
=C2=A0 auto-compression-mode: t
=C2=A0 line-number-mode: = t
=C2=A0 transient-mark-mode: t

Recent m= essages:
[backspace 67108911 backspace backspace backspace]
=
[67108911 backspace backspace backspace 114]
[backspace back= space backspace 114 101]
[backspace backspace 114 101 109]
<= div>[backspace 114 101 109 111]
[114 101 109 111 118]
[= 101 109 111 118 101]
[109 111 118 101 5]
(eldoc-schedul= e-timer)
funcall-interactively: End of buffer [4 times]

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message dired fo= rmat-spec rfc822 mml
mml-sec epg epg-config gnus-util mm-decode m= m-bodies mm-encode
mail-parse rfc2231 mailabbrev gmm-utils mailhe= ader sendmail rfc2047
rfc2045 ietf-drums mm-util help-fns mail-pr= svr mail-utils kmacro
cl-extra help-mode easymenu cl-loaddefs pca= se cl-lib time-date mule-util
japan-util tooltip eldoc electric u= niquify ediff-hook vc-hooks
lisp-float-type mwheel x-win term/com= mon-win x-dnd tool-bar dnd fontset
image regexp-opt fringe tabula= ted-list newcomment elisp-mode lisp-mode
prog-mode register page = menu-bar rfn-eshadow timer select scroll-bar
mouse jit-lock font-= lock syntax facemenu font-core frame cl-generic cham
georgian utf= -8-lang misc-lang vietnamese tibetan thai tai-viet lao
korean jap= anese eucjp-ms cp51932 hebrew greek romanian slovak czech
europea= n ethiopic indian cyrillic chinese charscript case-table epa-hook
jka-cmpr-hook help simple abbrev minibuffer cl-preloaded nadvice
loaddefs button faces cus-face macroexp files text-properties overlay
sha1 md5 base64 format env code-pages mule custom widget
ha= shtable-print-readable backquote dbusbind inotify dynamic-setting
system-font-setting font-render-setting move-toolbar gtk x-toolkit x=
multi-tty make-network-process emacs)

Memory = information:
((conses 16 92247 8518)
=C2=A0(symbols 48 = 20094 0)
=C2=A0(miscs 40 474 146)
=C2=A0(strings 32 153= 72 4220)
=C2=A0(string-bytes 1 449613)
=C2=A0(vectors 1= 6 12977)
=C2=A0(vector-slots 8 514251 7318)
=C2=A0(floa= ts 8 166 121)
=C2=A0(intervals 56 223 10)
=C2=A0(buffer= s 976 11)
=C2=A0(heap 1024 40476 865))

--001a11403bf243adbe052bc95e11--