(font-lock-fontify-syntactic-keywords-region):
Make sure we stop when we reach the limit.
This commit is contained in:
parent
c9176b9f18
commit
434f8c111b
2 changed files with 7 additions and 3 deletions
|
@ -1,5 +1,8 @@
|
|||
2009-02-19 Stefan Monnier <monnier@iro.umontreal.ca>
|
||||
|
||||
* font-lock.el (font-lock-fontify-syntactic-keywords-region):
|
||||
Make sure we stop when we reach the limit.
|
||||
|
||||
* progmodes/sh-script.el (sh-font-lock-quoted-subshell): ' inside
|
||||
a "..." does not quote anything.
|
||||
|
||||
|
|
|
@ -1473,9 +1473,10 @@ START should be at the beginning of a line."
|
|||
;; Find an occurrence of `matcher' from `start' to `end'.
|
||||
(setq keyword (car keywords) matcher (car keyword))
|
||||
(goto-char start)
|
||||
(while (if (stringp matcher)
|
||||
(re-search-forward matcher end t)
|
||||
(funcall matcher end))
|
||||
(while (and (< (point) end)
|
||||
(if (stringp matcher)
|
||||
(re-search-forward matcher end t)
|
||||
(funcall matcher end)))
|
||||
;; Apply each highlight to this instance of `matcher', which may be
|
||||
;; specific highlights or more keywords anchored to `matcher'.
|
||||
(setq highlights (cdr keyword))
|
||||
|
|
Loading…
Add table
Reference in a new issue