[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: The new keymap functions

From: Lars Ingebrigtsen
Subject: Re: The new keymap functions
Date: Sat, 13 Nov 2021 16:24:47 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux)

Stefan Monnier <monnier@iro.umontreal.ca> writes:

> I hope you do that by changing the C code of `define-key`, because doing
> it right from outside of it is hard (see recent discussion about it).

I missed that bit of the discussion (I only saw the first bugfix post):

> Actually, it's not guaranteed.  Try it with:
>     (let ((parent (make-sparse-keymap))
>           (child (make-keymap)))
>       (set-keymap-parent child parent)
>       (define-key parent [?a] nil)
>       (define-key child  [?a] 'bar)
>       child)

So the function as posted didn't work in that case...  hm...  yes, I
guess it has to be done in C.

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

reply via email to

[Prev in Thread] Current Thread [Next in Thread]