GNU bug report logs - #61436
Emacs Freezing With Java Files

Previous Next

Package: emacs;

Reported by: Hank Greenburg <hank.greenburg <at> protonmail.com>

Date: Sat, 11 Feb 2023 20:47:02 UTC

Severity: normal

Found in versions 30.0.50, 29.1.50

Done: Alan Mackenzie <acm <at> muc.de>

Bug is archived. No further changes may be made.

Full log


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

From: Jens Schmidt <jschmidt4gnu <at> vodafonemail.de>
To: Alan Mackenzie <acm <at> muc.de>
Cc: Robert Weiner <rsw <at> gnu.org>, Hank Greenburg <hank.greenburg <at> protonmail.com>,
 Mats Lidell <mats.lidell <at> lidells.se>, Eli Zaretskii <eliz <at> gnu.org>,
 rswgnu <at> gmail.com, 61436 <at> debbugs.gnu.org
Subject: Re: bug#61436: Emacs Freezing With Java Files
Date: Fri, 13 Oct 2023 22:42:04 +0200
Hi Alan,

Alan Mackenzie <acm <at> muc.de> writes:

> To solve the bug, I'm amending the macro c-beginning-of-defun-1 so that
> it only stops at a debug-prompt-regexp position when it also found a {.
> Otherwise it will keep looping until it finds a better position or BOB.

Thanks.

> Then please confirm that the bug is
> indeed fixed.

For the fun of it I tried Hank's initial testcase as well, which is a
bit less straight-forward to set up.  The freezes are indeed gone with
your patch.  But I noticed that which-function-mode, when rapidly moving
through the file, cannot always determine the current function name,
then displaying "[n/a]" in the mode line.

And indeed, when executing the simplified test case

  ./src/emacs -Q -l ~/tmp/init.el +181 ~/tmp/P1.java

and then immediately hitting C-M-a, point jumps to the beginning of the
preceeding catch clause (point=5779 of 18142) instead of BOD.

This behavior is again tied to the `defun-prompt-regexp' used by
Hyperbole - without that regexp C-M-a jumps to the real BOD.




This bug report was last modified 1 year and 115 days ago.

Previous Next


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