GNU bug report logs - #72759
31.0.50; Emacs hangs with open-paren-in-column-0-is-defun-start set to nil

Previous Next

Package: emacs;

Reported by: Eshel Yaron <me <at> eshelyaron.com>

Date: Thu, 22 Aug 2024 10:09:01 UTC

Severity: normal

Found in version 31.0.50

Fixed in version 30.1

Done: Eshel Yaron <me <at> eshelyaron.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Eli Zaretskii <eliz <at> gnu.org>
To: Eshel Yaron <me <at> eshelyaron.com>
Cc: 72759 <at> debbugs.gnu.org
Subject: bug#72759: 31.0.50; Emacs hangs with open-paren-in-column-0-is-defun-start set to nil
Date: Fri, 23 Aug 2024 09:56:15 +0300
> From: Eshel Yaron <me <at> eshelyaron.com>
> Cc: 72759 <at> debbugs.gnu.org
> Date: Fri, 23 Aug 2024 07:54:25 +0200
> 
> Hi Eli,
> 
> Eli Zaretskii <eliz <at> gnu.org> writes:
> 
> >> >> diff --git a/lisp/emacs-lisp/checkdoc.el b/lisp/emacs-lisp/checkdoc.el
> >> >> index 949ca6b74ad..65226d8ee44 100644
> >> >> --- a/lisp/emacs-lisp/checkdoc.el
> >> >> +++ b/lisp/emacs-lisp/checkdoc.el
> >> >> @@ -981,7 +981,7 @@ checkdoc-next-docstring
> >> >>  Return nil if there are no more doc strings."
> >> >>    (let (found)
> >> >>      (while (and (not (setq found (checkdoc--next-docstring)))
> >> >> -                (beginning-of-defun -1)))
> >> >> +                (beginning-of-defun-raw -1)))
> >> >>      found))
> 
> > I'm trying to understand what kind of behavior change could be caused
> > by your proposed change, which is why what beginning-of-defun-raw does
> > and beginning-of-defun doesn't is important, especially if some user
> > options can affect that.  E.g., does anything change in this scenario
> > if defun-prompt-regexp is non-nil?
> 
> This change is the correct also when defun-prompt-regexp is non-nil.
> Take a look at beginning-of-defun, it just calls beginning-of-defun-raw
> after possibly pushing a mark, and then it calls beginning-of-line.
> We're not interested in pushing a mark here, neither do we want to move
> back to beginning of the line after each call (that yields an infloop),
> so beginning-of-defun-raw fits the bill precisely.

Thanks, feel free to install this, then.




This bug report was last modified 330 days ago.

Previous Next


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