GNU bug report logs -
#23445
24.5; freeze in sh mode with show-paren-mode
Previous Next
Reported by: Vincent Lefevre <vincent <at> vinc17.net>
Date: Wed, 4 May 2016 12:09:02 UTC
Severity: normal
Tags: moreinfo
Merged with 19852,
22112,
22381
Found in versions 24.5, 25.0.50
Fixed in versions 25.1, 25.1.50.1
Done: Marcin Borkowski <mbork <at> mbork.pl>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
Vincent Lefevre <vincent <at> vinc17.net> writes:
> On 2016-05-04 16:30:14 +0200, Nicolas Richard wrote:
>> Thanks for the report and the recipe. I can reproduce it on 24.5 but not
>> on the emacs-25 branch, so I guess this was fixed in the meantime and
>> I'm closing your report. Feel free to ask if you need more information.
>
> OK. If someone has a patch (or knows the commit the fixed the bug),
> I'd be interested.
Not sure, but it could be this one :
commit 1bab3cefc133e06aaf4a48efb1623d1b458ab212
Author: Tassilo Horn <tsdh <at> gnu.org>
Date: Mon Oct 26 08:01:18 2015 +0100
Fix infinite loop in sh-script's SMIE code
* lisp/progmodes/sh-script.el (sh-smie-sh-forward-token): Fix infinite
loop (bug#21747).
diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el
index fbb4a90..baed27b 100644
--- a/lisp/progmodes/sh-script.el
+++ b/lisp/progmodes/sh-script.el
@@ -1920,10 +1920,11 @@ Does not preserve point."
;; Pretend the here-document is a "newline representing a
;; semi-colon", since the here-doc otherwise covers the newline(s).
";")
- (let ((semi (sh-smie--newline-semi-p)))
- (forward-line 1)
- (if (or semi (eobp)) ";"
- (sh-smie-sh-forward-token))))
+ (unless (eobp)
+ (let ((semi (sh-smie--newline-semi-p)))
+ (forward-line 1)
+ (if (or semi (eobp)) ";"
+ (sh-smie-sh-forward-token)))))
(forward-comment (point-max))
(cond
((looking-at "\\\\\n") (forward-line 1) (sh-smie-sh-forward-token))
This bug report was last modified 9 years and 21 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.