GNU bug report logs - #5264
23.1; `repeat' should not hard-code the set of affected commands

Previous Next

Package: emacs;

Reported by: "Drew Adams" <drew.adams <at> oracle.com>

Date: Tue, 6 Oct 2009 18:55:07 UTC

Severity: minor

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 5264 in the body.
You can then email your comments to 5264 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-submit-list <at> lists.donarmstrong.com, svenjoac <at> gmx.de, Emacs Bugs <bug-gnu-emacs <at> gnu.org>:
bug#5264; Package emacs. (Wed, 09 Dec 2009 09:45:06 GMT) Full text and rfc822 format available.

Message #3 received at submit <at> debbugs.gnu.org (full text, mbox):

From: "Drew Adams" <drew.adams <at> oracle.com>
To: <bug-gnu-emacs <at> gnu.org>
Subject: bug#5264: 23.1; `repeat' should not hard-code the set of affected commands
Date: Thu, 24 Dec 2009 07:30:20 -0800
emacs -Q
 
In the definition of command `repeat':
 
(if (memq last-repeatable-command
    '(exit-minibuffer
      minibuffer-complete-and-exit
      self-insert-and-exit))
 
This list of affected commands should not be hard-coded.  If user code
uses different functions from `exit-minibuffer' and
`minibuffer-complete-and-exit', then users must redefine `repeat' to
accommodate this command difference.  The `repeat' definition should
be more flexible than that.
 
This list of commands should be treated the same way we treat the list
of dangerous commands (`repeat-too-dangerous'): define a variable
whose value is the list of commands - do not hard-code the list.
 
 
 
In GNU Emacs 23.1.1 (i386-mingw-nt5.1.2600)
 of 2009-07-29 on SOFT-MJASON
Windowing system distributor `Microsoft Corp.', version 5.1.2600
configured using `configure --with-gcc (4.4)'
 

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#5264; Package emacs. (Mon, 10 Feb 2014 03:30:03 GMT) Full text and rfc822 format available.

Message #6 received at 5264 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: "Drew Adams" <drew.adams <at> oracle.com>
Cc: 5264 <at> debbugs.gnu.org
Subject: Re: bug#5264: 23.1;
 `repeat' should not hard-code the set of affected commands
Date: Sun, 09 Feb 2014 19:28:14 -0800
"Drew Adams" <drew.adams <at> oracle.com> writes:

> In the definition of command `repeat':
>
> (if (memq last-repeatable-command
>     '(exit-minibuffer
>       minibuffer-complete-and-exit
>       self-insert-and-exit))

[...]

> This list of commands should be treated the same way we treat the list
> of dangerous commands (`repeat-too-dangerous'): define a variable
> whose value is the list of commands - do not hard-code the list.

I agree, but probably not during the feature freeze.

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




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#5264; Package emacs. (Wed, 27 Apr 2016 21:18:02 GMT) Full text and rfc822 format available.

Message #9 received at 5264 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: "Drew Adams" <drew.adams <at> oracle.com>
Cc: 5264 <at> debbugs.gnu.org
Subject: Re: bug#5264: 23.1;
 `repeat' should not hard-code the set of affected commands
Date: Wed, 27 Apr 2016 23:17:43 +0200
"Drew Adams" <drew.adams <at> oracle.com> writes:

> In the definition of command `repeat':
>
> (if (memq last-repeatable-command
>     '(exit-minibuffer
>       minibuffer-complete-and-exit
>       self-insert-and-exit))
>
> This list of affected commands should not be hard-coded.  If user code
> uses different functions from `exit-minibuffer' and
> `minibuffer-complete-and-exit', then users must redefine `repeat' to
> accommodate this command difference.  The `repeat' definition should
> be more flexible than that.
>
> This list of commands should be treated the same way we treat the list
> of dangerous commands (`repeat-too-dangerous'): define a variable
> whose value is the list of commands - do not hard-code the list.

But what it is this does?  If `last-repeatable-command' is any of these
commands, then we...  repeat the first command in `command-history'
instead?  What does that do, exactly?

    (if (memq last-repeatable-command '(exit-minibuffer
					minibuffer-complete-and-exit
					self-insert-and-exit))
        (let ((repeat-command (car command-history)))
          (repeat-message "Repeating %S" repeat-command)
          (eval repeat-command))
      (if (null repeat-arg)
          (repeat-message "Repeating command %S" last-repeatable-command)
        (setq current-prefix-arg repeat-arg)
        (repeat-message
	 "Repeating command %S %S" repeat-arg last-repeatable-command))


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




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#5264; Package emacs. (Sun, 18 Jul 2021 18:09:02 GMT) Full text and rfc822 format available.

Message #12 received at 5264 <at> debbugs.gnu.org (full text, mbox):

From: Drew Adams <drew.adams <at> oracle.com>
To: Lars Ingebrigtsen <larsi <at> gnus.org>
Cc: "5264 <at> debbugs.gnu.org" <5264 <at> debbugs.gnu.org>
Subject: RE: [External] : Re: bug#5264: 23.1; `repeat' should not hard-code
 the set of affected commands
Date: Sun, 18 Jul 2021 15:40:07 +0000
> > In the definition of command `repeat':
> >
> > (if (memq last-repeatable-command
> >     '(exit-minibuffer
> >       minibuffer-complete-and-exit
> >       self-insert-and-exit))
> >
> > This list of affected commands should not be hard-coded.
> 
> As far as I can tell, this list is gone from `repeat' in Emacs 28, so
> I'm closing this bug report.  If I missed something here, please respond
> to the debbugs address and we'll reopen.

If you say so.  The most recent snapshot (Windows) I have
of Emacs 28 (Jan 15, 2021) still has it:

(if (memq last-repeatable-command '(exit-minibuffer
                                    minibuffer-complete-and-exit
                                    self-insert-and-exit))




bug closed, send any further explanations to 5264 <at> debbugs.gnu.org and "Drew Adams" <drew.adams <at> oracle.com> Request was from Lars Ingebrigtsen <larsi <at> gnus.org> to control <at> debbugs.gnu.org. (Sun, 18 Jul 2021 18:13:03 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#5264; Package emacs. (Sun, 18 Jul 2021 19:04:02 GMT) Full text and rfc822 format available.

Message #17 received at 5264 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: Drew Adams <drew.adams <at> oracle.com>
Cc: 5264 <at> debbugs.gnu.org, larsi <at> gnus.org
Subject: Re: bug#5264: [External] : Re: bug#5264: 23.1;
 `repeat' should not hard-code the set of affected commands
Date: Sun, 18 Jul 2021 22:03:45 +0300
> From: Drew Adams <drew.adams <at> oracle.com>
> Date: Sun, 18 Jul 2021 15:40:07 +0000
> Cc: "5264 <at> debbugs.gnu.org" <5264 <at> debbugs.gnu.org>
> 
> > As far as I can tell, this list is gone from `repeat' in Emacs 28, so
> > I'm closing this bug report.  If I missed something here, please respond
> > to the debbugs address and we'll reopen.
> 
> If you say so.  The most recent snapshot (Windows) I have
> of Emacs 28 (Jan 15, 2021) still has it:

That's a 6-month old snapshot.  And you can verify this is no longer
in Emacs by looking at the sources on Savannah, the URL was posted
many times in the past.




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#5264; Package emacs. (Sun, 18 Jul 2021 19:43:01 GMT) Full text and rfc822 format available.

Message #20 received at 5264 <at> debbugs.gnu.org (full text, mbox):

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: "Drew Adams" <drew.adams <at> oracle.com>
Cc: 5264 <at> debbugs.gnu.org
Subject: Re: bug#5264: 23.1; `repeat' should not hard-code the set of
 affected commands
Date: Sun, 18 Jul 2021 16:39:09 +0200
"Drew Adams" <drew.adams <at> oracle.com> writes:

> In the definition of command `repeat':
>
> (if (memq last-repeatable-command
>     '(exit-minibuffer
>       minibuffer-complete-and-exit
>       self-insert-and-exit))
>
> This list of affected commands should not be hard-coded.

As far as I can tell, this list is gone from `repeat' in Emacs 28, so
I'm closing this bug report.  If I missed something here, please respond
to the debbugs address and we'll reopen.

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




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Mon, 16 Aug 2021 11:24:06 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 253 days ago.

Previous Next


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