From: Noam Postavsky <npostavs@gmail.com>
To: No Wayman <iarchivedmywholelife@gmail.com>
Cc: 39805@debbugs.gnu.org
Subject: bug#39805: 28.0.50; scan-sexps (scan_lists) incorrectly parsing circular list
Date: Wed, 26 Feb 2020 20:38:12 -0500 [thread overview]
Message-ID: <87pne0ajy3.fsf@gmail.com> (raw)
In-Reply-To: <87wo89ghix.fsf@gmail.com> (No Wayman's message of "Wed, 26 Feb 2020 16:33:59 -0500")
# seems to be long standing
found 39805 25.3
tags 39805 + confirmed
quit
No Wayman <iarchivedmywholelife@gmail.com> writes:
> While developing a package that utilizes circular lists, I ran
> into a bug when trying to describe-variable
> a variable that contains circular lists. I've hewed it down to the
> following:
>
> ** Minimal Reproducible Case
>
> #+begin_src emacs-lisp :results raw h replace
> (condition-case-unless-debug err
> (with-temp-buffer
> (insert "(#9=() :key val)")
> (pp-buffer)
> nil)
It doesn't fail if the buffer is changed to emacs-lisp-mode before the
pp-buffer call. I guess scan-sexps doesn't handle the #N= correctly
unless the syntax-table has been set for emacs-lisp. I note that
pp-to-string does some setup on its temp buffer, so maybe
describe-variable needs to do that too.
For the record, to reproduce the error from describe-variable, a
slightly less minimal example is needed (because the value must be more
than 68 characters long to trigger pretty printing)
(setq vv '(#1=(a b) :key val #1# :key val :key val :key val :key val))
(describe-variable 'vv)
next prev parent reply other threads:[~2020-02-27 1:38 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-26 21:33 bug#39805: 28.0.50; scan-sexps (scan_lists) incorrectly parsing circular list No Wayman
2020-02-27 1:38 ` Noam Postavsky [this message]
2020-02-27 17:22 ` No Wayman
2020-02-28 2:34 ` Noam Postavsky
2020-02-28 4:01 ` No Wayman
2020-03-04 3:09 ` Noam Postavsky
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87pne0ajy3.fsf@gmail.com \
--to=npostavs@gmail.com \
--cc=39805@debbugs.gnu.org \
--cc=iarchivedmywholelife@gmail.com \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).