]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix debbugs#20146
authorAlan Mackenzie <acm@muc.de>
Fri, 20 Mar 2015 15:39:37 +0000 (15:39 +0000)
committerAlan Mackenzie <acm@muc.de>
Fri, 20 Mar 2015 15:39:37 +0000 (15:39 +0000)
* font-lock.el (font-lock-extend-jit-lock-region-after-change):
Return the calculated values, as per spec.

lisp/ChangeLog
lisp/font-lock.el

index ac99cd5ec39482dd872d270398cd64f45791da36..cecec469ed8f4e5202429d4e579d09ffcc81776d 100644 (file)
@@ -1,3 +1,10 @@
+2015-03-20  Alan Mackenzie  <acm@muc.de>
+
+       Fix debbugs#20146
+
+       * font-lock.el (font-lock-extend-jit-lock-region-after-change):
+       Return the calculated values, as per spec.
+
 2015-03-20  Dmitry Gutov  <dgutov@yandex.ru>
 
        * progmodes/ruby-mode.el (ruby-font-lock-keywords): Move `at_exit'
index 6ec6c9f11964cd111c391254fe93e9621417f55e..1838a0f02b46ad4b695ba6923ae09855681aab30 100644 (file)
@@ -1325,11 +1325,13 @@ This function does 2 things:
       (when (memq 'font-lock-extend-region-wholelines
                   font-lock-extend-region-functions)
         (goto-char beg)
-        (setq jit-lock-start (min jit-lock-start (line-beginning-position)))
+        (setq beg (min jit-lock-start (line-beginning-position)))
         (goto-char end)
-        (setq jit-lock-end
+        (setq end
               (max jit-lock-end
-                   (if (bolp) (point) (line-beginning-position 2))))))))
+                   (if (bolp) (point) (line-beginning-position 2)))))
+      (setq jit-lock-start beg
+           jit-lock-end end))))
 
 (defun font-lock-fontify-block (&optional arg)
   "Fontify some lines the way `font-lock-fontify-buffer' would.