Package: emacs;
Reported by: Ian Miller <emacs <at> soroban.fastmail.fm>
Date: Sun, 7 Sep 2008 11:45:04 UTC
Severity: normal
Tags: unreproducible
Done: Chong Yidong <cyd <at> stupidchicken.com>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 911 in the body.
You can then email your comments to 911 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
View this report as an mbox folder, status mbox, maintainer mbox
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.Ian Miller <emacs <at> soroban.fastmail.fm>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #5 received at submit <at> emacsbugs.donarmstrong.com (full text, mbox):
From: Ian Miller <emacs <at> soroban.fastmail.fm> To: emacs-pretest-bug <at> gnu.org Subject: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Sun, 7 Sep 2008 12:36:42 +0100
Please write in English if possible, because the Emacs maintainers usually do not have translators to read other languages for them. Your bug report will be posted to the emacs-pretest-bug <at> gnu.org mailing list. Please describe exactly what actions triggered the bug and the precise symptoms of the bug: Whenever I select "File->New Frame" (C-x 5 2) a new frame does not appear and I receive the message "Variable binding depth exceeds max-specpdl-size". This seems to be caused by any use of custom-set-faces in the .emacs file. When I remove the custom-set-faces code from .emacs, the bug does not occur. Example custom-set-faces in .emacs that causes the bug: (custom-set-faces ;; custom-set-faces was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. '(default ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))))) If Emacs crashed, and you have the Emacs process in the gdb debugger, please include the output from the following gdb commands: `bt full' and `xbacktrace'. If you would like to further debug the crash, please read the file /usr/share/emacs/23.0.60/etc/DEBUG for instructions. In GNU Emacs 23.0.60.1 (x86_64-redhat-linux-gnu, GTK+ Version 2.12.11) of 2008-08-01 on x86-1 Windowing system distributor `The X.Org Foundation', version 11.0.10499905 configured using `configure '--build=x86_64-redhat-linux-gnu' '--host=x86_64-redhat-linux-gnu' '--target=x86_64-redhat-linux-gnu' '--program-prefix=' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' '--includedir=/usr/include' '--libdir=/usr/lib64' '--libexecdir=/usr/libexec' '--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' '--infodir=/usr/share/info' 'build_alias=x86_64-redhat-linux-gnu' 'host_alias=x86_64-redhat-linux-gnu' 'target_alias=x86_64-redhat-linux-gnu' 'CFLAGS=-DMAIL_USE_LOCKF -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic'' Important settings: value of $LC_ALL: nil value of $LC_COLLATE: nil value of $LC_CTYPE: nil value of $LC_MESSAGES: nil value of $LC_MONETARY: nil value of $LC_NUMERIC: nil value of $LC_TIME: nil value of $LANG: en_GB.utf8 value of $XMODIFIERS: nil locale-coding-system: utf-8-unix default-enable-multibyte-characters: t Major mode: Lisp Interaction Minor modes in effect: show-paren-mode: t mouse-wheel-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t global-auto-composition-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Recent input: <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <help-echo> <menu-bar> <file> <make-frame> M-x r e p o <tab> r <tab> <return> Recent messages: Loading /usr/share/emacs/site-lisp/site-start.d/igrep-init.el (source)...done Loading /usr/share/emacs/site-lisp/site-start.d/muse-init.el (source)...done Loading /usr/share/emacs/site-lisp/site-start.d/php-mode-init.el (source)...done Loading /usr/share/emacs/site-lisp/site-start.d/po-mode-init.el (source)...done Loading /usr/share/emacs/site-lisp/site-start.d/rpm-spec-mode-init.el (source)...done Loading gnus...done Loading paren...done For information about GNU Emacs and the GNU system, type C-h C-a. display-color-cells: Variable binding depth exceeds max-specpdl-size Making completion list...
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.martin rudalics <rudalics <at> gmx.at>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #10 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: martin rudalics <rudalics <at> gmx.at> To: 911 <at> debbugs.gnu.org Cc: Ian Miller <emacs <at> soroban.fastmail.fm> Subject: Re: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Sun, 07 Sep 2008 16:23:42 +0200
> Example custom-set-faces in .emacs that causes the bug: > > (custom-set-faces > ;; custom-set-faces was added by Custom. > ;; If you edit it by hand, you could mess it up, so be careful. > ;; Your init file should contain only one such instance. > ;; If there is more than one, they won't work right. > '(default ((t (:stipple nil :background "DarkSlateGray" > :foreground "wheat" :inverse-video nil :box nil :strike-through > nil :overline nil :underline nil :slant normal :weight normal > :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))))) Can you reproduce the bug with an .emacs that contains just this form and nothing else? > display-color-cells: Variable binding depth exceeds max-specpdl-size Does this occur in `x-display-color-cells'? martin
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.Ian Miller <emacs <at> soroban.fastmail.fm>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #15 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: Ian Miller <emacs <at> soroban.fastmail.fm> To: martin rudalics <rudalics <at> gmx.at> Cc: 911 <at> debbugs.gnu.org Subject: Re: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Sun, 7 Sep 2008 17:56:33 +0100
On Sun, Sep 07, 2008 at 04:23:42PM +0200, martin rudalics wrote: > > Example custom-set-faces in .emacs that causes the bug: > > > > (custom-set-faces > > ;; custom-set-faces was added by Custom. > > ;; If you edit it by hand, you could mess it up, so be careful. > > ;; Your init file should contain only one such instance. > > ;; If there is more than one, they won't work right. > > '(default ((t (:stipple nil :background "DarkSlateGray" > > :foreground "wheat" :inverse-video nil :box nil :strike-through > > nil :overline nil :underline nil :slant normal :weight normal > > :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))))) > > Can you reproduce the bug with an .emacs that contains just this form > and nothing else? Yes. The bug is still present even when .emacs consists of only the above. > > display-color-cells: Variable binding depth exceeds max-specpdl-size > > Does this occur in `x-display-color-cells'? I'm not quite sure what you mean by this... but I can evaluate (x-display-color-cells) in the scratch buffer without any apparent error? (x-display-color-cells) 1677721
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.martin rudalics <rudalics <at> gmx.at>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #20 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: martin rudalics <rudalics <at> gmx.at> To: Ian Miller <emacs <at> soroban.fastmail.fm> Cc: 911 <at> debbugs.gnu.org Subject: Re: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Sun, 07 Sep 2008 20:47:40 +0200
>> Can you reproduce the bug with an .emacs that contains just this form >> and nothing else? > > Yes. The bug is still present even when .emacs consists of only the above. And it happens when you evaluate that form in *scratch*? I'm asking because I can't reproduce it here. Maybe you should also try with a more recent checkout. > I'm not quite sure what you mean by this... but I can evaluate > (x-display-color-cells) in the scratch buffer without any apparent error? > > (x-display-color-cells) > 1677721 I wondered what precisely in `display-color-cells' could trigger the Variable binding depth exceeds max-specpdl-size. Can you debug `display-color-cells'? martin
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.Ian Miller <emacs <at> soroban.fastmail.fm>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #25 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: Ian Miller <emacs <at> soroban.fastmail.fm> To: martin rudalics <rudalics <at> gmx.at> Cc: 911 <at> debbugs.gnu.org Subject: Re: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Mon, 8 Sep 2008 00:42:26 +0100
On Sun, Sep 07, 2008 at 08:47:40PM +0200, martin rudalics wrote: > > And it happens when you evaluate that form in *scratch*? I'm asking > because I can't reproduce it here. Maybe you should also try with a > more recent checkout. If I delete .emacs, and then evaluate the form in *scratch* then the same symptoms occur. If however, I first create a new frame, and then evaluate the form in that new frame, then the symptoms only occur in the frame in which I evaluated the form but I am able to create new frames (with the new font colours) from every other frame, including the original. I have tried this with the latest sources from CVS and get the same results. > I wondered what precisely in `display-color-cells' could trigger the > Variable binding depth exceeds max-specpdl-size. Can you debug > `display-color-cells'? This is what I get if I toggle-debug-on-error (I hope this is useful?): Debugger entered--Lisp error: (error "Variable binding depth exceeds max-specpdl-size") framep-on-display(#<frame emacs <at> baso 0xed2800>) display-color-cells(#<frame emacs <at> baso 0xed2800>) face-spec-set-match-display(((min-colors 88) (class color)) #<frame emacs <at> baso 0xed2800>) face-spec-choose((((... ...) (:foreground "white" :background "blue1")) ((...) (:foreground "white" :background "blue")) (t (:slant italic))) #<frame emacs <at> baso 0xed2800>) face-spec-match-p(custom-themed (((... ...) (:foreground "white" :background "blue1")) ((...) (:foreground "white" :background "blue")) (t (:slant italic))) #<frame emacs <at> baso 0xed2800>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) x-create-frame-with-faces(nil) make-frame() make-frame-command() call-interactively(make-frame-command nil nil)
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.martin rudalics <rudalics <at> gmx.at>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #30 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: martin rudalics <rudalics <at> gmx.at> To: Ian Miller <emacs <at> soroban.fastmail.fm> Cc: 911 <at> debbugs.gnu.org Subject: Re: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Mon, 08 Sep 2008 15:29:40 +0200
> This is what I get if I toggle-debug-on-error > (I hope this is useful?): > > Debugger entered--Lisp error: (error "Variable binding depth exceeds max-specpdl-size") > framep-on-display(#<frame emacs <at> baso 0xed2800>) > display-color-cells(#<frame emacs <at> baso 0xed2800>) > face-spec-set-match-display(((min-colors 88) (class color)) #<frame emacs <at> baso 0xed2800>) > face-spec-choose((((... ...) (:foreground "white" :background "blue1")) ((...) (:foreground "white" :background "blue")) (t (:slant italic))) #<frame emacs <at> baso 0xed2800>) > face-spec-match-p(custom-themed (((... ...) (:foreground "white" :background "blue1")) ((...) (:foreground "white" :background "blue")) (t (:slant italic))) #<frame emacs <at> baso 0xed2800>) > frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) > internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) > set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") > face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) > face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) > frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) > internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) > set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") > face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) > face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) > frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) [...] > internal-set-lisp-face-attribute(default :background "#ffffff" #<frame emacs <at> baso 0x10107a0>) > set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "#ffffff") > face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 90 :width normal :foundry "unknown" :family "DejaVu Sans Mono"))) > face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) > frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) > internal-set-lisp-face-attribute(default :background "DarkSlateGray" #<frame emacs <at> baso 0x10107a0>) > set-face-attribute(default #<frame emacs <at> baso 0x10107a0> :background "DarkSlateGray") > face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 121 :width normal :foundry "unknown" :family "DejaVu Sans Mono")))) > face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) > frame-set-background-mode(#<frame emacs <at> baso 0x10107a0>) > x-create-frame-with-faces(nil) > make-frame() > make-frame-command() > call-interactively(make-frame-command nil nil) IIUC it has entered infinite recursion where `frame-set-background-mode' is entered over and over again. Somehow alternating between a "#ffffff" and "DarkSlateGray" background, very interesting. But I don't really understand where this happens :-( martin
Glenn Morris <rgm <at> gnu.org>
to control <at> emacsbugs.donarmstrong.com
.
(Thu, 11 Sep 2008 23:25:04 GMT) Full text and rfc822 format available.bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.martin rudalics <rudalics <at> gmx.at>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #37 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: martin rudalics <rudalics <at> gmx.at> To: 911 <at> debbugs.gnu.org Cc: Ian Miller <emacs <at> soroban.fastmail.fm> Subject: Re: bug#911: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Sun, 14 Sep 2008 15:50:05 +0200
Ian, I can't reproduce this here. Could your try to edebug the functions `face-spec-set-2' and `face-spec-recalc' to find out why (or better how) in the trace > > face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple > nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box > nil :strike-through nil :overline nil :underline nil :slant normal > :weight normal :height 90 :width normal :foundry "unknown" :family > "DejaVu Sans Mono"))) > > face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) [...] > > face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple > nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil > :box nil :strike-through nil :overline nil :underline nil :slant normal > :weight normal :height 121 :width normal :foundry "unknown" :family > "DejaVu Sans Mono")))) > > face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) the function `face-spec-set-2' is called alternately with different backgrounds. That is, edebug these two functions, call C-x 5 2 or whatever you have to make a new frame, and tell me whether (1) `face-spec-recalc' in one and the same call invokes `face-spec-set-2' at least twice (where an invocation should cause `face-spec-set-2' to really call `set-face-attributes'), or (2) `face-spec-recalc' is called at least twice when making a new frame. Please complain immediately whem my recipe is unclear. Thanks in advance, martin.
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.Ian Miller <emacs <at> soroban.fastmail.fm>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #42 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: Ian Miller <emacs <at> soroban.fastmail.fm> To: martin rudalics <rudalics <at> gmx.at> Cc: 911 <at> debbugs.gnu.org Subject: Re: bug#911: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Tue, 16 Sep 2008 13:11:49 +0100
On Sun, Sep 14, 2008 at 03:50:05PM +0200, martin rudalics wrote: > Ian, > > I can't reproduce this here. Could your try to edebug the functions > `face-spec-set-2' and `face-spec-recalc' to find out why (or better how) > in the trace > > > > face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t :stipple > > nil :background "#ffffff" :foreground "#000000" :inverse-video nil :box > > nil :strike-through nil :overline nil :underline nil :slant normal > > :weight normal :height 90 :width normal :foundry "unknown" :family > > "DejaVu Sans Mono"))) > > > face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) > [...] > > > face-spec-set-2(default #<frame emacs <at> baso 0x10107a0> ((t (:stipple > > nil :background "DarkSlateGray" :foreground "wheat" :inverse-video nil > > :box nil :strike-through nil :overline nil :underline nil :slant normal > > :weight normal :height 121 :width normal :foundry "unknown" :family > > "DejaVu Sans Mono")))) > > > face-spec-recalc(default #<frame emacs <at> baso 0x10107a0>) > > the function `face-spec-set-2' is called alternately with different > backgrounds. That is, edebug these two functions, call C-x 5 2 or > whatever you have to make a new frame, and tell me whether Martin, When I tried to instrument those two functions, there was no problem with face-spec-recalc, but face-spec-set-2 refused to instrument with the following complaint: edebug-syntax-error: Invalid read syntax: "Expected lambda expression" (defun face-spec-set-2 (face frame spec) "Set the face attributes of FACE on FRAME according to SPEC." (let* ((attrs (face-spec-choose spec frame))) (while attrs (let ((attribute (car attrs)) (value (car (cdr attrs)))) ;; Support some old-style attribute names and values. (case attribute (:bold (setq attribute :weight value (if value 'bold 'normal))) (:italic (setq attribute :slant value (if value 'italic 'normal))) ((:foreground :background) ^ this is the cursor marking the syntax error > (1) `face-spec-recalc' in one and the same call invokes > `face-spec-set-2' at least twice (where an invocation should cause > `face-spec-set-2' to really call `set-face-attributes'), or > > (2) `face-spec-recalc' is called at least twice when making a new frame. When I edebug face-spec-recalc and attempt to create a new frame, each time I press 'T' to Trace Fast the function appears to be re-entered, and this appears to go on indefinitely? Additionally a frame *is* created now, but it does not appear automatically on the screen - however, it can be accessed via the Buffers->Frames menu, and it does not use the colour scheme specified in .emacs. Also, when edebug reaches face-spec-recalc, I get the following console message with each subsequent step of edebug (sorry, I don't know if this is relevant, I am a complete novice when it comes to emacs debugging!): (emacs:21944): Gtk-CRITICAL **: gtk_box_pack_start: assertion `child->parent ==NULL' failed cheers, ian
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.martin rudalics <rudalics <at> gmx.at>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #47 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: martin rudalics <rudalics <at> gmx.at> To: Ian Miller <emacs <at> soroban.fastmail.fm> Cc: 911 <at> debbugs.gnu.org Subject: Re: bug#911: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Tue, 16 Sep 2008 14:50:55 +0200
> When I tried to instrument those two functions, there was no problem > with face-spec-recalc, but face-spec-set-2 refused to instrument > with the following complaint: > > edebug-syntax-error: Invalid read syntax: "Expected lambda expression" Sorry. Please append the code below at the end of your .emacs and send me the contents of the *face-spec-set-2* buffer after the bug occurred. Thanks, martin. ;;;; Code starts here (require 'cl) (require 'faces) (defun face-spec-set-2 (face frame spec) "Set the face attributes of FACE on FRAME according to SPEC." (with-current-buffer (get-buffer-create "*face-spec-set-2*") (insert (format "face %s frame %s spec %s" face frame spec)) (insert "\n")) (let* ((attrs (face-spec-choose spec frame))) (while attrs (let ((attribute (car attrs)) (value (car (cdr attrs)))) ;; Support some old-style attribute names and values. (case attribute (:bold (setq attribute :weight value (if value 'bold 'normal))) (:italic (setq attribute :slant value (if value 'italic 'normal))) ((:foreground :background) ;; Compatibility with 20.x. Some bogus face specs seem to ;; exist containing things like `:foreground nil'. (if (null value) (setq value 'unspecified))) (t (unless (assq attribute face-x-resources) (setq attribute nil)))) (when attribute (set-face-attribute face frame attribute value))) (setq attrs (cdr (cdr attrs)))))) ;;;; Code ends here
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.Ian Miller <emacs <at> soroban.fastmail.fm>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #52 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: Ian Miller <emacs <at> soroban.fastmail.fm> To: martin rudalics <rudalics <at> gmx.at> Cc: 911 <at> debbugs.gnu.org Subject: Re: bug#911: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Tue, 16 Sep 2008 15:17:42 +0100
[Message part 1 (text/plain, inline)]
On Tue, Sep 16, 2008 at 02:50:55PM +0200, martin rudalics wrote: > > When I tried to instrument those two functions, there was no problem > > with face-spec-recalc, but face-spec-set-2 refused to instrument > > with the following complaint: > > > > edebug-syntax-error: Invalid read syntax: "Expected lambda expression" > > Sorry. Please append the code below at the end of your .emacs and send > me the contents of the *face-spec-set-2* buffer after the bug occurred. > Please see attached for contents of this buffer. cheers, ian
[face-spec-set-2.txt (text/plain, attachment)]
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.martin rudalics <rudalics <at> gmx.at>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #57 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: martin rudalics <rudalics <at> gmx.at> To: Ian Miller <emacs <at> soroban.fastmail.fm> Cc: 911 <at> debbugs.gnu.org Subject: Re: bug#911: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Tue, 16 Sep 2008 16:54:47 +0200
>> Sorry. Please append the code below at the end of your .emacs and send >> me the contents of the *face-spec-set-2* buffer after the bug occurred. > > Please see attached for contents of this buffer. My bad. When I tried this here it got me a buffer with a couple of lines. Yours is 600K :-( apologies to you and everyone on this list. Please try again with the following (it should print only calls for the default face and distinguish them according to where they are called in `face-spec-recalc'). But please don't post it on the list this time if it gets too large. martin ;;;; Code starts here (require 'cl) (require 'faces) (defvar face-counter 0) (defun face-spec-recalc (face frame) "Reset the face attributes of FACE on FRAME according to its specs. This applies the defface/custom spec first, then the custom theme specs, then the override spec." (face-spec-reset-face face frame) (setq face-counter (1+ face-counter)) (let ((face-sym (or (get face 'face-alias) face))) (or (get face 'customized-face) (get face 'saved-face) (progn (when (eq face 'default) (with-current-buffer (get-buffer-create "*face-spec-set-2*") (insert (format "%s-1 face %s frame %s spec %s\n" face-counter face frame spec)))) (face-spec-set-2 face frame (face-default-spec face)))) (let ((theme-faces (reverse (get face-sym 'theme-face)))) (dolist (spec theme-faces) (when (eq face 'default) (with-current-buffer (get-buffer-create "*face-spec-set-2*") (insert (format "%s-2 face %s frame %s spec %s\n" face-counter face frame spec)))) (face-spec-set-2 face frame (cadr spec)))) (when (eq face 'default) (with-current-buffer (get-buffer-create "*face-spec-set-2*") (insert (format "%s-3 face %s frame %s spec %s\n" face-counter face frame spec)))) (face-spec-set-2 face frame (get face-sym 'face-override-spec)))) ;;;; Code ends here
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.Ian Miller <emacs <at> soroban.fastmail.fm>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #62 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: Ian Miller <emacs <at> soroban.fastmail.fm> To: martin rudalics <rudalics <at> gmx.at> Cc: 911 <at> debbugs.gnu.org Subject: Re: bug#911: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Wed, 17 Sep 2008 11:41:18 +0100
On Tue, Sep 16, 2008 at 05:01:25PM +0200, martin rudalics wrote: > Ahhh no ... > > The code below shouldn't get you any bugs because `spec' is undefined. > Martin, Sorry about the last post - my fault, I was in a hurry and didn't check size. Output from latest run here: http://emacs.fastmail.fm/face-spec-set-2.txt cheers, ian
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.martin rudalics <rudalics <at> gmx.at>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #67 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: martin rudalics <rudalics <at> gmx.at> To: 911 <at> debbugs.gnu.org Cc: Ian Miller <ian <at> soroban.fastmail.fm> Subject: Re: bug#911: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Sun, 21 Sep 2008 20:30:36 +0200
Ian Miller has patiently continued to debug this and we finally came to the conclusion that the following sequence of events leads to the error. Ian uses (custom-set-faces '(default ((t (... :background "DarkSlateGray" ...))))) When creating a new frame `frame-set-background-mode' gets called which eventually calls `face-spec-recalc'. The latter has this loop (dolist (spec theme-faces) (face-spec-set-2 face frame (cadr spec)))) which calls `face-spec-set-2' two times for the default face background, one time for #ffffff and one time for DarkSlateGray. `face-spec-set-2' calls `set-face-attribute', which calls `internal-set-lisp-face-attribute' which calls Fmodify_frame_parameters which calls `frame-set-background-mode' again. Now (>= (apply '+ (color-values "DarkSlateGrey")) (* (apply '+ (color-values "white")) .6)) evaluates to nil while (>= (apply '+ (color-values "#ffffff")) (* (apply '+ (color-values "white")) .6)) evaluates to t. This means that `bg-mode' never equals `old-bg-mode' but continuously alternates between 'light and 'dark, so `frame-set-background-mode' will call `face-spec-recalc' thus sending Emacs into a nasty loop. Note that the looping behavior is due to the second call in the dolist (that for DarkSlateGrey). The first call (for #ffffff) terminates. I'm not sure how to fix this because that looping has no specific entry point. In fact, Ian told me > Incidently, whilst testing I have found that the same bug does indeed > manifest itself elsewhere. Normally I have the toolbar disabled in my > .emacs, but after stripping everything out of .emacs for testing > purposes, I noticed that I get the following errors whenever I hover > over an icon in the toolbar: > > Error while displaying tooltip: (error Variable binding depth exceeds > max-specpdl-size) > Read a directory, to operate on its files > Error while displaying tooltip: (error Variable binding depth exceeds > max-specpdl-size) > Read an existing file into an Emacs buffer which seems due to the fact that x_create_tip_frame calls `modify-frame-parameters' ... Anyone out there with good ideas for a fix? martin
Chong Yidong <cyd <at> stupidchicken.com>
:Ian Miller <emacs <at> soroban.fastmail.fm>
:Message #72 received at 911-done <at> emacsbugs.donarmstrong.com (full text, mbox):
From: Chong Yidong <cyd <at> stupidchicken.com> To: martin rudalics <rudalics <at> gmx.at> Cc: 911-done <at> debbugs.gnu.org, Ian Miller <ian <at> soroban.fastmail.fm> Subject: Re: bug#911: 23.0.60; custom-set-faces causes "New Frame" to fail Date: Wed, 24 Sep 2008 16:25:39 -0400
> When creating a new frame `frame-set-background-mode' gets called > which eventually calls `face-spec-recalc'... which calls > `face-spec-set-2' two times for the default face background, one time > for #ffffff and one time for DarkSlateGray. `face-spec-set-2' calls > `set-face-attribute', which calls `internal-set-lisp-face-attribute' > which calls Fmodify_frame_parameters which calls > `frame-set-background-mode' again. The Emacs face code strikes again, huh. > (>= (apply '+ (color-values "DarkSlateGrey")) > (* (apply '+ (color-values "white")) .6)) > > evaluates to nil while > > (>= (apply '+ (color-values "#ffffff")) > (* (apply '+ (color-values "white")) .6)) > > evaluates to t. This means that `bg-mode' never equals `old-bg-mode' > but continuously alternates between 'light and 'dark, so > `frame-set-background-mode' will call `face-spec-recalc' thus sending > Emacs into a nasty loop. > > Note that the looping behavior is due to the second call in the dolist > (that for DarkSlateGrey). The first call (for #ffffff) terminates. > > I'm not sure how to fix this because that looping has no specific entry > point. How about defining a variable `frame-set-background-mode-bg-mode'? If it's nil, frame-set-background-mode uses the existing calculation to determine whether it's light or dark; if it's non-nil, it uses that existing value. This should prevent the oscillation.
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.martin rudalics <rudalics <at> gmx.at>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #77 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: martin rudalics <rudalics <at> gmx.at> To: Chong Yidong <cyd <at> stupidchicken.com> Cc: 911 <at> debbugs.gnu.org, Ian Miller <ian <at> soroban.fastmail.fm> Subject: Re: bug#911: 23.0.60; custom-set-faces causes "New Frame" to fail Date: Thu, 25 Sep 2008 11:11:27 +0200
> How about defining a variable `frame-set-background-mode-bg-mode'? If > it's nil, frame-set-background-mode uses the existing calculation to > determine whether it's light or dark; if it's non-nil, it uses that > existing value. This should prevent the oscillation. But who would be responsible for setting and resetting that variable? Hardly `frame-set-background-mode' itself. Would we make this a frame parameter so the command loop can reset it and allow to change it once and only once for a command? Otherwise, we might risk reentering the loop with the next call of `frame-set-background-mode'. martin BTW, it seems you already closed bug#911 ...
Chong Yidong <cyd <at> stupidchicken.com>
to control <at> emacsbugs.donarmstrong.com
.
(Thu, 25 Sep 2008 12:50:03 GMT) Full text and rfc822 format available.bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.Chong Yidong <cyd <at> stupidchicken.com>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #84 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: Chong Yidong <cyd <at> stupidchicken.com> To: martin rudalics <rudalics <at> gmx.at> Cc: 911 <at> debbugs.gnu.org, Ian Miller <ian <at> soroban.fastmail.fm> Subject: Re: bug#911: 23.0.60; custom-set-faces causes "New Frame" to fail Date: Thu, 25 Sep 2008 10:31:16 -0400
martin rudalics <rudalics <at> gmx.at> writes: >> How about defining a variable `frame-set-background-mode-bg-mode'? If >> it's nil, frame-set-background-mode uses the existing calculation to >> determine whether it's light or dark; if it's non-nil, it uses that >> existing value. This should prevent the oscillation. > > But who would be responsible for setting and resetting that variable? > Hardly `frame-set-background-mode' itself. Would we make this a frame > parameter so the command loop can reset it and allow to change it once > and only once for a command? Otherwise, we might risk reentering the > loop with the next call of `frame-set-background-mode'. Why not in frame-set-background-mode itself? Then, when it's set, subsequent calls to that function could be no-ops. > BTW, it seems you already closed bug#911 ... Sorry, I must have mistyped when trying to close a different bug. Reopened.
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.martin rudalics <rudalics <at> gmx.at>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #89 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: martin rudalics <rudalics <at> gmx.at> To: Chong Yidong <cyd <at> stupidchicken.com> Cc: 911 <at> debbugs.gnu.org, Ian Miller <ian <at> soroban.fastmail.fm> Subject: Re: bug#911: 23.0.60; custom-set-faces causes "New Frame" to fail Date: Thu, 25 Sep 2008 17:17:43 +0200
> Why not in frame-set-background-mode itself? Then, when it's set, > subsequent calls to that function could be no-ops. We have to reset it eventually. And we have to cater for the situation that a user might want to open two frames in one and the same command. So I suppose the only reliable place is the command loop. And we must make sure that the background determined by the user is considered. martin
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.Chong Yidong <cyd <at> stupidchicken.com>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #94 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: Chong Yidong <cyd <at> stupidchicken.com> To: martin rudalics <rudalics <at> gmx.at> Cc: 911 <at> debbugs.gnu.org, Ian Miller <ian <at> soroban.fastmail.fm> Subject: Re: bug#911: 23.0.60; custom-set-faces causes "New Frame" to fail Date: Sun, 28 Sep 2008 17:13:02 -0400
> > Why not in frame-set-background-mode itself? Then, when it's set, > > subsequent calls to that function could be no-ops. > > We have to reset it eventually. And we have to cater for the situation > that a user might want to open two frames in one and the same command. > So I suppose the only reliable place is the command loop. And we must > make sure that the background determined by the user is considered. I'm not sure what you mean. To be precise, here's a patch implementing the approach I'm suggesting (indentated for readability). Would it work? (I can't reproduce the original bug myself, so maybe Ian can test it.) *** trunk/lisp/faces.el.~1.425.~ 2008-09-24 12:51:07.000000000 -0400 --- trunk/lisp/faces.el 2008-09-28 17:10:55.000000000 -0400 *************** *** 1839,1848 **** --- 1839,1851 ---- (declare-function x-get-resource "frame.c" (attribute class &optional component subclass)) + (defvar inhibit-frame-set-background-mode nil) + (defun frame-set-background-mode (frame) "Set up display-dependent faces on FRAME. Display-dependent faces are those which have different definitions according to the `background-mode' and `display-type' frame parameters." + (unless inhibit-frame-set-background-mode (let* ((bg-resource (and (window-system frame) (x-get-resource "backgroundMode" "BackgroundMode"))) *************** *** 1893,1899 **** (frame-parameter frame 'display-type))) (unless (and (eq bg-mode old-bg-mode) (eq display-type old-display-type)) ! (let ((locally-modified-faces nil)) ;; Before modifying the frame parameters, we collect a list of ;; faces that don't match what their face-spec says they should ;; look like; we then avoid changing these faces below. --- 1896,1905 ---- (frame-parameter frame 'display-type))) (unless (and (eq bg-mode old-bg-mode) (eq display-type old-display-type)) ! (let ((locally-modified-faces nil) ! ;; Prevent face-spec-recalc from calling this function ! ;; again, resulting in a loop. ! (inhibit-frame-set-background-mode t)) ;; Before modifying the frame parameters, we collect a list of ;; faces that don't match what their face-spec says they should ;; look like; we then avoid changing these faces below. *************** *** 1915,1920 **** --- 1921,1927 ---- (dolist (face (face-list)) (unless (memq face locally-modified-faces) (face-spec-recalc face frame))))))) + ) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available."Tim Van Holder" <tim.vanholder <at> gmail.com>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #99 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: "Tim Van Holder" <tim.vanholder <at> gmail.com> To: "martin rudalics" <rudalics <at> gmx.at> Cc: 598 <at> debbugs.gnu.org, "Chong Yidong" <cyd <at> stupidchicken.com>, 911 <at> debbugs.gnu.org Subject: Re: bug#598: 23.0.60; frame size issue (--geometry or default-frame-alist) when using customized default face Date: Wed, 1 Oct 2008 11:52:47 +0200
On Wed, Oct 1, 2008 at 10:47 AM, martin rudalics <rudalics <at> gmx.at> wrote: >> I'm also getting max-specpdl-size exceeded on C-x 5 2, so I cannot check >> the >> previously observed behaviour that even when the initial frame is >> erratically >> sized, subsequent frames are fine. > > That's most likely bug#911 (aka nine-eleven) see > > http://debbugs.gnu.org/cgi/bugreport.cgi?bug=911 > > Could you try the recipe Chong gave there? I tried a slightly different recipe (below) and that made the error go away. I assume Chong's will work as well - I just wanted to set the inhibit flag as early as possible (and I wasn't 100% sure whether or not the let would use the defvar'd flag instead of its own scoped var). --- faces.el.~1.425.~ 2008-09-25 10:49:34.000000000 +0200 +++ faces.el 2008-10-01 11:48:01.000000000 +0200 @@ -1839,10 +1839,13 @@ variable with `setq'; this won't have th (declare-function x-get-resource "frame.c" (attribute class &optional component subclass)) +(defvar inhibit-frame-set-background-mode nil) (defun frame-set-background-mode (frame) "Set up display-dependent faces on FRAME. Display-dependent faces are those which have different definitions according to the `background-mode' and `display-type' frame parameters." + (unless inhibit-frame-set-background-mode + (setq inhibit-frame-set-background-mode t) (let* ((bg-resource (and (window-system frame) (x-get-resource "backgroundMode" "BackgroundMode"))) @@ -1914,7 +1917,8 @@ according to the `background-mode' and ` ;; parameters, unless they have been locally modified. (dolist (face (face-list)) (unless (memq face locally-modified-faces) - (face-spec-recalc face frame))))))) + (face-spec-recalc face frame)))))) + (setq inhibit-frame-set-background-mode nil))) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:bug#911
; Package emacs
.
Full text and rfc822 format available.martin rudalics <rudalics <at> gmx.at>
:Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
Full text and rfc822 format available.Message #104 received at 911 <at> emacsbugs.donarmstrong.com (full text, mbox):
From: martin rudalics <rudalics <at> gmx.at> To: Tim Van Holder <tim.vanholder <at> gmail.com> Cc: 598 <at> debbugs.gnu.org, Chong Yidong <cyd <at> stupidchicken.com>, 911 <at> debbugs.gnu.org Subject: Re: bug#598: 23.0.60; frame size issue (--geometry or default-frame-alist) when using customized default face Date: Wed, 01 Oct 2008 15:05:24 +0200
> I tried a slightly different recipe (below) and that made the error go away. I suppose the original problem (that of erratic size changes) persists? martin
Chong Yidong <cyd <at> stupidchicken.com>
:Ian Miller <emacs <at> soroban.fastmail.fm>
:Message #109 received at 911-done <at> emacsbugs.donarmstrong.com (full text, mbox):
From: Chong Yidong <cyd <at> stupidchicken.com> To: 911-done <at> debbugs.gnu.org Subject: Re: 23.0.60; custom-set-faces causes "New Frame" to fail (max-specpdl-size) Date: Thu, 02 Oct 2008 16:21:16 -0400
I've checked the patch into CVS.
Debbugs Internal Request <don <at> donarmstrong.com>
to internal_control <at> emacsbugs.donarmstrong.com
.
(Fri, 31 Oct 2008 14:24:03 GMT) Full text and rfc822 format available.
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.