From: Stefan Monnier Date: Sun, 20 Sep 2015 16:04:52 +0000 (-0400) Subject: Don't assume syntax-begin-function is a symbol. X-Git-Tag: emacs-25.0.90~1224^2~71 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=9474c70a8442e052bd7b192a515a4fdb1834f49a;p=emacs.git Don't assume syntax-begin-function is a symbol. * lisp/font-lock.el (font-lock-compile-keywords): Don't assume syntax-begin-function is a symbol. --- diff --git a/lisp/font-lock.el b/lisp/font-lock.el index d93cf7184ca..e2660bfab91 100644 --- a/lisp/font-lock.el +++ b/lisp/font-lock.el @@ -1752,7 +1752,8 @@ If SYNTACTIC-KEYWORDS is non-nil, it means these keywords are used for (if (and (not syntactic-keywords) (let ((beg-function syntax-begin-function)) (or (eq beg-function 'beginning-of-defun) - (get beg-function 'font-lock-syntax-paren-check))) + (if (symbolp beg-function) + (get beg-function 'font-lock-syntax-paren-check)))) (not beginning-of-defun-function)) ;; Try to detect when a string or comment contains something that ;; looks like a defun and would thus confuse font-lock.