GNU bug report logs -
#73827
[ELPA] [PATCH] register-list fails on "Unprintable entity" registers
Previous Next
Reported by: Alex Bochannek <alex <at> bochannek.com>
Date: Tue, 15 Oct 2024 23:26:02 UTC
Severity: normal
Tags: patch
Done: Stefan Kangas <stefankangas <at> gmail.com>
Bug is archived. No further changes may be made.
Full log
Message #20 received at 73827 <at> debbugs.gnu.org (full text, mbox):
Philip Kaludercic <philipk <at> posteo.net> writes:
> Alex Bochannek <alex <at> bochannek.com> writes:
>
>> --- /Users/awb/.emacs.d/elpa/register-list-0.1/register-list.el.~1~ 2023-01-10 19:36:23
>> +++ /Users/awb/.emacs.d/elpa/register-list-0.1/register-list.el 2024-10-15 15:49:37
>> @@ -483,8 +483,8 @@
>> (t "error"))
>> (cond ((window-configuration-p (car key)) "W")
>> ((frame-configuration-p (car key)) "F")
>> - ((stringp (car key)) "R")
>> ((string= "Unprintable entity" (car key)) "?")
>
> The change confuses me, are we sure that (car key) must be a string at
> this point? If not, should be prefer `equal' over `string='?
>
>> + ((stringp (car key)) "R")
The change simply swaps the stringp and string= predicates in the cond.
If there is a register with "Unprintable entity" (which desktop.el
produces), it would not show up correctly as a "?" (assuming "?" has
been added to register-list-default-type).
Looking at register-alist in my .emacs.desktop, it is always the string
"Unprintable entity" and never a symbol. Whether it's string= or equal
shouldn't matter, because the difference in error handling between the
two isn't relevant here.
Unrelated, I looked into how to get frameset support in register-list
and the way framesets are stored in register-alist is very different.
I'll submit another patch for that, although it isn't particularly
elegant.
> You can try out
>
> M-x package-vc-install register-list RET
>
> that should give you a checkout. You can then make your changes as
> usual and then prepare a patch using vc-prepare-patch or git-format-patch(1).
Perfect, thank you! Didn't know about package-vc-install.
--
Alex.
This bug report was last modified 99 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.