Control: tags -1 patch I've attached the patch from
http://debbugs.gnu.org/cgi/bugreport.cgi?bug=23445#23 which fixes this bug (it works for me). -- Vincent Lefèvre <vinc...@vinc17.net> - Web: <https://www.vinc17.net/> 100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/> Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)
commit 1bab3cefc133e06aaf4a48efb1623d1b458ab212 Author: Tassilo Horn <t...@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))