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

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

bug#30070: 27.0.50; cl-print sometimes prints self-referencing objects a


From: Stefan Monnier
Subject: bug#30070: 27.0.50; cl-print sometimes prints self-referencing objects as #1=#<thing>
Date: Wed, 10 Jan 2018 15:39:46 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

> That gives me "#1=#<thing>".  That's weird because the printed
> representation of the thing doesn't refer to itself.

Yes, it's a known misfeature (to me at least).  I don't know how we
could fix it, tho: the cycle-detection is done in a preprocessing phase
which doesn't know about any print format (nor about cl-print), so by
the time we learn the the object will be printed as "#<thing>", we have
already printed "#1=".

To fix it, I have the impression that we'd have to make cl-print a lot
more complex, and potentially its API as well (e.g. add a matching
cl-preprocess method additionally to cl-print-object).


        Stefan





reply via email to

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