GNU bug report logs - #15020
24.3.50; `kmacro-view-ring-2nd' wrong arg, confusion, more

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Severity: minor; Reported by: Drew Adams <drew.adams@HIDDEN>; dated Sun, 4 Aug 2013 03:22:02 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.

Message received at 15020 <at> debbugs.gnu.org:


Received: (at 15020) by debbugs.gnu.org; 29 Apr 2016 13:23:56 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri Apr 29 09:23:56 2016
Received: from localhost ([127.0.0.1]:54107 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1aw8Oh-0001xd-Ji
	for submit <at> debbugs.gnu.org; Fri, 29 Apr 2016 09:23:56 -0400
Received: from hermes.netfonds.no ([80.91.224.195]:54850)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <larsi@HIDDEN>) id 1aw8Og-0001xV-0Z
 for 15020 <at> debbugs.gnu.org; Fri, 29 Apr 2016 09:23:54 -0400
Received: from cm-84.215.1.64.getinternet.no ([84.215.1.64] helo=mouse)
 by hermes.netfonds.no with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128)
 (Exim 4.84_2) (envelope-from <larsi@HIDDEN>)
 id 1aw8Od-0008Bw-FE; Fri, 29 Apr 2016 15:23:53 +0200
From: Lars Ingebrigtsen <larsi@HIDDEN>
To: Drew Adams <drew.adams@HIDDEN>
Subject: Re: bug#15020: 24.3.50;
 `kmacro-view-ring-2nd' wrong arg, confusion, more
References: <bde678f3-3055-4c67-b996-f91d8e0a0eb9@default>
Date: Fri, 29 Apr 2016 15:23:51 +0200
In-Reply-To: <bde678f3-3055-4c67-b996-f91d8e0a0eb9@default> (Drew Adams's
 message of "Sat, 3 Aug 2013 20:21:02 -0700 (PDT)")
Message-ID: <87vb308s60.fsf@HIDDEN>
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.1.50 (gnu/linux)
MIME-Version: 1.0
Content-Type: text/plain
X-Spam-Score: 0.0 (/)
X-Debbugs-Envelope-To: 15020
Cc: 15020 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: 0.0 (/)

Drew Adams <drew.adams@HIDDEN> writes:

> 1. This call in  `kmacro-view-ring-2nd' is wrong:
>
>    (kmacro-display (car (car kmacro-ring)) "2nd macro")
>
>    It seems to be missing argument TRUNC between the two args it has.

I've now pushed a fix.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#15020; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 4 Aug 2013 03:21:44 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Sat Aug 03 23:21:44 2013
Received: from localhost ([127.0.0.1]:38862 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1V5ot5-0001PM-CP
	for submit <at> debbugs.gnu.org; Sat, 03 Aug 2013 23:21:43 -0400
Received: from eggs.gnu.org ([208.118.235.92]:44228)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <drew.adams@HIDDEN>) id 1V5ot2-0001P2-2j
 for submit <at> debbugs.gnu.org; Sat, 03 Aug 2013 23:21:41 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <drew.adams@HIDDEN>) id 1V5osm-0004H2-Pa
 for submit <at> debbugs.gnu.org; Sat, 03 Aug 2013 23:21:34 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=-99.2 required=5.0 tests=BAYES_50,USER_IN_WHITELIST
 autolearn=disabled version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:42481)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <drew.adams@HIDDEN>) id 1V5osm-0004Gy-Mx
 for submit <at> debbugs.gnu.org; Sat, 03 Aug 2013 23:21:24 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:45932)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <drew.adams@HIDDEN>) id 1V5osd-0003Us-FC
 for bug-gnu-emacs@HIDDEN; Sat, 03 Aug 2013 23:21:24 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <drew.adams@HIDDEN>) id 1V5osU-0004DY-R2
 for bug-gnu-emacs@HIDDEN; Sat, 03 Aug 2013 23:21:15 -0400
Received: from aserp1040.oracle.com ([141.146.126.69]:36273)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <drew.adams@HIDDEN>) id 1V5osU-0004DU-Ku
 for bug-gnu-emacs@HIDDEN; Sat, 03 Aug 2013 23:21:06 -0400
Received: from acsinet21.oracle.com (acsinet21.oracle.com [141.146.126.237])
 by aserp1040.oracle.com (Sentrion-MTA-4.3.1/Sentrion-MTA-4.3.1) with ESMTP id
 r743L4Ck014483
 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK)
 for <bug-gnu-emacs@HIDDEN>; Sun, 4 Aug 2013 03:21:05 GMT
Received: from aserz7022.oracle.com (aserz7022.oracle.com [141.146.126.231])
 by acsinet21.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r743L3u7020896
 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO)
 for <bug-gnu-emacs@HIDDEN>; Sun, 4 Aug 2013 03:21:04 GMT
Received: from abhmt104.oracle.com (abhmt104.oracle.com [141.146.116.56])
 by aserz7022.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r743L3vX015754
 for <bug-gnu-emacs@HIDDEN>; Sun, 4 Aug 2013 03:21:03 GMT
MIME-Version: 1.0
Message-ID: <bde678f3-3055-4c67-b996-f91d8e0a0eb9@default>
Date: Sat, 3 Aug 2013 20:21:02 -0700 (PDT)
From: Drew Adams <drew.adams@HIDDEN>
To: bug-gnu-emacs@HIDDEN
Subject: 24.3.50; `kmacro-view-ring-2nd' wrong arg, confusion, more
X-Priority: 3
X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.8  (707110) [OL
 12.0.6668.5000 (x86)]
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: quoted-printable
X-Source-IP: acsinet21.oracle.com [141.146.126.237]
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic]
X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address
 (bad octet value).
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -2.4 (--)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <http://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <http://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <http://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -2.4 (--)

1. This call in  `kmacro-view-ring-2nd' is wrong:

   (kmacro-display (car (car kmacro-ring)) "2nd macro")

   It seems to be missing argument TRUNC between the two args it has.

2. The `kmacro-view-ring-2nd' doc string is wrong when it refers to "the
   current head of".  It should say "the second macro in", just as do
   the doc strings of `kmacro-call-ring-2nd' and
   `kmacro-call-ring-2nd-repeat'.  The car of `kmacro-ring' is really
   the second ring item, not the head.

   The doc and commentary is a bit confused about this.  The doc string
   of `kmacro-ring-head' calls the head a "pseudo head".  Pick one
   coherent terminology and stick with it: either `last-kbd-macro', aka
   the "current" macro, is the first macro in the ring or it is not in
   the ring of macros at all.

   There is confusion between the concrete list used to represent part
   of the ring, and which holds the second and subsequent ring elements,
   and the abstract ring itself, which holds all of the ring elements,
   including the head element, `kmacro-ring-head'.

   Present something coherent to the user, including the reader of the
   code, comments, and doc strings.  Example: `kmacro-ring-max' refers
   not to the max length of the "macro ring", as it says, but to the max
   length of list `kmacro-ring'.  Example: `kmacro-pop-ring' does not
   pop the ring.  It pops the list `kmacro-ring', moving the second item
   of the ring to the head of the ring.  Contrast such terminology with
   that of `kmacro-ring-empty-p', which tests the abstract ring, not
   just the list `kmacro-ring'.

   There is plenty of confusion here, with "the ring" meaning sometimes
   the list `kmacro-ring' (an unfortunate name) and sometimes the
   abstract ring, whose first macro is `last-kbd-macro' and whose first
   element is `kmacro-ring-head'.

3. Please provide doc strings for these functions:

    kmacro-keyboard-quit
    kmacro-split-ring-element
    kmacro-get-repeat-prefix
    kmacro-execute-from-register
    kmacro-step-edit-prompt
    kmacro-step-edit-query
    kmacro-step-edit-insert
    kmacro-step-edit-pre-command
    kmacro-step-edit-minibuf-setup
    kmacro-step-edit-post-command

   Some of those have the longest code in the file.

4. Please document the undocumente parameters in these functions:

    kmacro-display-counter (uppercase)
    kmacro-add-counter (uppercase)
    kmacro-repeat-on-last-key (uppercase)
    kmacro-exec-ring-item - no ARG description
    kmacro-call-ring-2nd - no ARG description
    kmacro-call-ring-2nd-repeat - no ARG description
    kmacro-cycle-ring-next - no _ARG description (say it is unused & why
                             it is there at all)
    kmacro-cycle-ring-previous - no _ARG description (say...)
    kmacro-delete-ring-head - no _ARG description (say...)
    kmacro-end-macro (uppercase)
    kmacro-call-macro - no ARG, no NO-REPEAT, no END-MACRO
    kmacro-end-or-call-macro - no NO-REPEAT
    kmacro-end-or-call-macro-repeat - no ARG
    kmacro-end-and-call-macro - no NO-REPEAT
    kmacro-end-call-mouse - no EVENT
    kmacro-lambda-form - none of the parameters are documented:
                    MAC, COUNTER, or FORMAT
    kmacro-extract-lambda - no MAC
    kmacro-bind-to-key - no _ARG description (say...)
    kmacro-view-macro - no _ARG description (say...)
    kmacro-view-macro-repeat - no ARG
    kmacro-edit-macro-repeat - no ARG
    kmacro-edit-macro - no ARG (and put `kmacro-repeat' between `...')
   =20

In GNU Emacs 24.3.50.1 (i686-pc-mingw32)
 of 2013-07-21 on ODIEONE
Bzr revision: 113485 lekktu@HIDDEN
Windowing system distributor `Microsoft Corp.', version 6.1.7601
Configured using:
 `configure --prefix=3D/c/Devel/emacs/binary --enable-checking=3Dyes,glyphs
 CFLAGS=3D-O0 -g3 LDFLAGS=3D-Lc:/Devel/emacs/lib
 CPPFLAGS=3D-Ic:/Devel/emacs/include'




Acknowledgement sent to Drew Adams <drew.adams@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#15020; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Fri, 29 Apr 2016 13:30:03 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.