emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] master 6392d1f 40/47: Bind optional parameters earlier.


From: Jackson Ray Hamilton
Subject: [elpa] master 6392d1f 40/47: Bind optional parameters earlier.
Date: Mon, 18 May 2015 09:52:05 +0000

branch: master
commit 6392d1f3e0764414f019e4c76baf25b66101f5f6
Author: Jackson Ray Hamilton <address@hidden>
Commit: Jackson Ray Hamilton <address@hidden>

    Bind optional parameters earlier.
---
 context-coloring.el |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/context-coloring.el b/context-coloring.el
index 057b4d8..c7a3f08 100644
--- a/context-coloring.el
+++ b/context-coloring.el
@@ -172,7 +172,9 @@ the END point (exclusive) with the face corresponding to 
LEVEL."
   (when (or context-coloring-comments-and-strings
             context-coloring-syntactic-comments
             context-coloring-syntactic-strings)
-    (let ((font-lock-syntactic-face-function
+    (let ((min (or min (point-min)))
+          (max (or max (point-max)))
+          (font-lock-syntactic-face-function
            (cond
             ((and context-coloring-syntactic-comments
                   (not context-coloring-syntactic-strings))
@@ -183,12 +185,10 @@ the END point (exclusive) with the face corresponding to 
LEVEL."
             (t
              font-lock-syntactic-face-function))))
       (save-excursion
-        (font-lock-fontify-syntactically-region (or min (point-min))
-                                                (or max (point-max)))
+        (font-lock-fontify-syntactically-region min max)
         ;; TODO: Make configurable at the dispatch level.
         (when (eq major-mode 'emacs-lisp-mode)
-          (font-lock-fontify-keywords-region (or min (point-min))
-                                             (or max (point-max))))))))
+          (font-lock-fontify-keywords-region min max))))))
 
 
 ;;; js2-mode colorization



reply via email to

[Prev in Thread] Current Thread [Next in Thread]