unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Narendra Joshi <narendraj9@gmail.com>
To: emacs-devel@gnu.org
Subject: Re: repeat-mode: Setting `repeat-map' property to a keymap object fails
Date: Thu, 25 Nov 2021 19:09:42 +0100	[thread overview]
Message-ID: <875ysg1509.fsf@gmail.com> (raw)
In-Reply-To: 86y25cvf6p.fsf@mail.linkov.net

Juri Linkov <juri@linkov.net> writes:

>> I tried to use a `keymap' object as the value of the `repeat-map'
>> property of a symbol/command and it failed. I think the change below
>> would avoid the problem. The problem is that `boundp` throws an error
>> for anything other than a symbol value.
>>
>> diff --git a/lisp/repeat.el b/lisp/repeat.el
>> index 4dcd353e34..32ffb1884f 100644
>> --- a/lisp/repeat.el
>> +++ b/lisp/repeat.el
>> @@ -416,7 +416,7 @@ repeat-post-hook
>>                           (and (symbolp real-this-command)
>>                                (get real-this-command 'repeat-map)))))
>>          (when rep-map
>> -          (when (boundp rep-map)
>> +          (when (and (symbolp rep-map) (boundp rep-map))
>>              (setq rep-map (symbol-value rep-map)))
>>            (let ((map (copy-keymap rep-map)))
>
> Thanks, fixed now.
>
Thanks. I see that it's merged to `emacs-28`. How/when would it end up
on the master branch? I am just curious about the overall process. 

Best,
-- 
Narendra Joshi




  reply	other threads:[~2021-11-25 18:09 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-24 20:39 repeat-mode: Setting `repeat-map' property to a keymap object fails Narendra Joshi
2021-11-25  7:59 ` Juri Linkov
2021-11-25 18:09   ` Narendra Joshi [this message]
2021-11-25 18:34     ` Robert Pluim

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=875ysg1509.fsf@gmail.com \
    --to=narendraj9@gmail.com \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).