all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Drew Adams <drew.adams@oracle.com>
To: 54115@debbugs.gnu.org
Subject: bug#54115: 27.2; `face-remap-set-base' bug with only two args
Date: Tue, 22 Feb 2022 17:47:33 +0000	[thread overview]
Message-ID: <SJ0PR10MB54888E6A86B2204638475333F33B9@SJ0PR10MB5488.namprd10.prod.outlook.com> (raw)

(I see the same problem (same code) in an Emacs 28 pretest snapshot.)

emacs -Q

Eval the source-code defun of `face-remap-set-base'.

M-x debug-on-entry face-remap-set-base

Evaluate (face-remap-set-base 'variable-pitch 'default).

Debugger entered--Lisp error: (wrong-type-argument listp default)
* car(default)
* (eq (car specs) face)
* (and (eq (car specs) face) (null (cdr specs)))
* (or (null specs) (and (eq (car specs) face) (null (cdr specs))))
* (if (or (null specs) (and (eq (car specs) face) (null (cdr specs)))) (face-remap-reset-base face) (make-local-variable 'face-remapping-alist) (let ((entry (assq face face-remapping-alist))) (if entry (setcar (last entry) specs) (setq face-remapping-alist (cons (list face specs) face-remapping-alist)))) (force-mode-line-update))
* (closure (t) (face &rest specs) "Set the base remapping of FACE in the current buff..." (while (and (consp specs) (not (null (car specs))) (null (cdr specs))) (setq specs (car specs))) (if (or (null specs) (and (eq (car specs) face) (null (cdr specs)))) (face-remap-reset-base face) (make-local-variable 'face-remapping-alist) (let ((entry (assq face face-remapping-alist))) (if entry (setcar (last entry) specs) (setq face-remapping-alist (cons (list face specs) face-remapping-alist)))) (force-mode-line-update)))(variable-pitch default)
* apply((closure (t) (face &rest specs) "Set the base remapping of FACE in the current buff..." (while (and (consp specs) (not (null (car specs))) (null (cdr specs))) (setq specs (car specs))) (if (or (null specs) (and (eq (car specs) face) (null (cdr specs)))) (face-remap-reset-base face) (make-local-variable 'face-remapping-alist) (let ((entry (assq face face-remapping-alist))) (if entry (setcar (last entry) specs) (setq face-remapping-alist (cons (list face specs) face-remapping-alist)))) (force-mode-line-update))) (variable-pitch default))
* face-remap-set-base(variable-pitch default)
  (progn (face-remap-set-base 'variable-pitch 'default))
  eval((progn (face-remap-set-base 'variable-pitch 'default)) t)
  elisp--eval-last-sexp(nil)
  eval-last-sexp(nil)
  funcall-interactively(eval-last-sexp nil)
  call-interactively(eval-last-sexp nil nil)
  command-execute(eval-last-sexp)

Should the test perhaps be this:

(if (or (null specs) (eq specs face)) ; default

instead of this?

(if (or (null specs)
	(and (eq (car specs) face)
        (null (cdr specs)))) ; default


In GNU Emacs 27.2 (build 1, x86_64-w64-mingw32)
 of 2021-03-26 built on CIRROCUMULUS
Repository revision: deef5efafb70f4b171265b896505b92b6eef24e6
Repository branch: HEAD
Windowing system distributor 'Microsoft Corp.', version 10.0.19043
System Description: Microsoft Windows 10 Pro (v10.0.2009.19043.1526)






             reply	other threads:[~2022-02-22 17:47 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-22 17:47 Drew Adams [this message]
2022-02-22 18:22 ` bug#54115: 27.2; `face-remap-set-base' bug with only two args Eli Zaretskii
2022-02-22 18:45   ` bug#54115: [External] : " Drew Adams
2022-02-22 19:16     ` Eli Zaretskii
2022-02-22 22:31       ` Drew Adams
2022-02-23 11:51 ` Lars Ingebrigtsen

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

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

  git send-email \
    --in-reply-to=SJ0PR10MB54888E6A86B2204638475333F33B9@SJ0PR10MB5488.namprd10.prod.outlook.com \
    --to=drew.adams@oracle.com \
    --cc=54115@debbugs.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 external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.