unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Jonas Bernoulli <jonas@bernoul.li>,
	Stefan Monnier <monnier@iro.umontreal.ca>,
	Lars Ingebrigtsen <larsi@gnus.org>
Cc: 62207@debbugs.gnu.org
Subject: bug#62207: 29.0.60; Trying to remove non-existent key binding instead adds a binding
Date: Wed, 15 Mar 2023 19:13:20 +0200	[thread overview]
Message-ID: <83pm9aq6of.fsf@gnu.org> (raw)
In-Reply-To: <875yb2gfqp.fsf@bernoul.li> (message from Jonas Bernoulli on Wed,  15 Mar 2023 17:07:42 +0100)

> From: Jonas Bernoulli <jonas@bernoul.li>
> Date: Wed, 15 Mar 2023 17:07:42 +0100
> 
> However if you try to remove a binding that does not actually exist,
> then the opposite happens, a "nil binding" is *added*:
> 
>   (let ((map (make-sparse-keymap)))
>     (keymap-unset map "i" t)
>     map)
>   => (keymap (105))

The same happens when you call define-key with REMOVE non-nil.
keymap-unset just calls define-key, and does little else.

Stefan, it sounds like the part of store_in_keymap after the label
keymap_end should do nothing if REMOVE is non-zero, am I right?





  parent reply	other threads:[~2023-03-15 17:13 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-15 16:07 bug#62207: 29.0.60; Trying to remove non-existent key binding instead adds a binding Jonas Bernoulli
2023-03-15 16:51 ` Jonas Bernoulli
2023-03-15 17:36   ` Robert Pluim
2023-03-15 18:12     ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-03-15 22:26       ` Jonas Bernoulli
2023-03-17 21:09         ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-03-20 18:46           ` Jonas Bernoulli
2023-03-20 21:25             ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-03-15 17:13 ` Eli Zaretskii [this message]
2023-03-15 17:39   ` Robert Pluim
2023-03-15 18:02   ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-03-17  8:23     ` Eli Zaretskii
2023-03-17  8:54       ` Robert Pluim
2023-03-17  9:55         ` Robert Pluim
2023-03-17 11:36           ` Eli Zaretskii
2023-03-17 13:20             ` Robert Pluim
2023-03-17 11:32         ` Eli Zaretskii
2023-03-17 13:20           ` Robert Pluim
2023-03-20 18:14             ` Jonas Bernoulli
2023-03-17 20:51           ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-03-18  5:51             ` Eli Zaretskii
2023-03-18 14:05               ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-03-18  9:43             ` Robert Pluim
2023-03-18 14:07               ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-03-20  9:09                 ` Robert Pluim
2023-03-20 12:17                   ` Eli Zaretskii
2023-03-20 15:03                   ` Stefan Monnier via Bug reports for GNU Emacs, the Swiss army knife of text editors
2023-03-20 15:27                     ` 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=83pm9aq6of.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=62207@debbugs.gnu.org \
    --cc=jonas@bernoul.li \
    --cc=larsi@gnus.org \
    --cc=monnier@iro.umontreal.ca \
    /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).