[Top][All Lists]

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

Re: Warnings about keymaps

From: Glenn Morris
Subject: Re: Warnings about keymaps
Date: Fri, 18 Sep 2009 18:25:27 -0400
User-agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/)

Stefan Monnier wrote:

> It may seem like a braindead case, but when comparing "broken code
> in corner cases" vs "incorrect warning in some cases", I prefer the
> incorrect warning.


>> I think it would be better to change define-derived-mode to not defvar
>> the map if it is already defined;
> I don't know how to do that.

Oh well, that makes two of us.

>> or to change easy-mode-defmap to not use defconst
> That might be an acceptable workaround.  But the underlying problem will
> still be there.

But under a carpet. :)

>> (are you saying users should not add key bindings to
>> log-edit-mode-map, for example?).
> That's unrelated: defconst only says that the variable's binding won't
> change, not that the object it is bound to is immutable.

I don't understand that distinction. I just read the doc of defconst:

    The intent is that neither programs nor users should ever change
    this value.

which seems clear to me.

reply via email to

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