bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#19217: 25.0.50; `C-M-x' (`eval-defun') on a `defface' that is not to


From: Stefan Monnier
Subject: bug#19217: 25.0.50; `C-M-x' (`eval-defun') on a `defface' that is not top-level
Date: Sun, 30 Nov 2014 22:51:22 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux)

> It is not uncommon to have a `defface' inside a condition such as (when
> (> emacs-major-version 23)...).

Obviously, I'm blindsided by looking mostly at bundled Elisp code, but
to get an idea of how common it might be, could you explain why you'd
want to wrap it in that way?
Also, pointers to code that do that would help.

> Currently, `C-M-x' has no effect on such a `defface' occurrence.

Yes, same problem for defvar/defcustom, of course.

> How about letting users redefine a `defface' with `C-M-x' even in this
> case?

I think I'd welcome a patch which fixes this well enough (including in
the case of C-u C-M-x).  The current way C-M-x handled defvar/defface is
hackish and ugly.  Extending this hack to code wrapped in a conditional
test would not be welcome.  But replacing the hack with something a bit
more generic would be nice.


        Stefan





reply via email to

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