GNU bug report logs - #75387
29.4; hideshow: hs-hide-level hides multiple top-level blocks as one

Previous Next

Package: emacs;

Reported by: Christoph Groth <christoph <at> grothesque.org>

Date: Sun, 5 Jan 2025 18:54:01 UTC

Severity: normal

Found in version 29.4

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #23 received at 75387 <at> debbugs.gnu.org (full text, mbox):

From: Christoph Groth <christoph <at> grothesque.org>
To: kobarity <kobarity <at> gmail.com>
Cc: Eli Zaretskii <eliz <at> gnu.org>, 75387 <at> debbugs.gnu.org
Subject: Re: bug#75387: 29.4; hideshow: hs-hide-level hides multiple
 top-level blocks as one
Date: Sun, 02 Feb 2025 23:41:28 +0100
kobarity wrote:

> I think I've found the root cause.  `python-nav-end-of-statement' may
> fail to find the end of a long triple-quoted string when the buffer is
> "fresh".  It uses the following code to find the end of
> a triple-quoted string:
>
> (...)
>
> Attached is a patch to fix this issue.  I changed the above search to
> searching for triple-quotes and checking syntax.  Checking syntax
> involves `syntax-ppss' and syntax properties up to the point are
> updated.

I verified that the patch indeed solves the issue for me and
does not seem to introduce any other problem.

These were the steps that I followed:

• In my Emacs 29.4 from Debian stable, I copied the function
  python-nav-end-of-statement to *scratch*.

• There, I manually applied the change from the patch.

• I evaluated the function definition.

• I tried to reproduce the issue in a “fresh” builder.py buffer, but it
  no longer appears.

Thanks
Christoph




This bug report was last modified 95 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.