[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/auctex 6a47321 5/6: Fix font-latex.el
From: |
Tassilo Horn |
Subject: |
[elpa] externals/auctex 6a47321 5/6: Fix font-latex.el |
Date: |
Thu, 25 Mar 2021 09:45:01 -0400 (EDT) |
branch: externals/auctex
commit 6a47321fcea175158aff810826307f4ea8388c6d
Author: Ikumi Keita <ikumi@ikumi.que.jp>
Commit: Ikumi Keita <ikumi@ikumi.que.jp>
Fix font-latex.el
* font-latex.el (font-latex-make-built-in-keywords): Defer making
`font-latex-match-*' buffer-local so that it attains sane default
value.
---
font-latex.el | 23 ++++++++++++++++-------
1 file changed, 16 insertions(+), 7 deletions(-)
diff --git a/font-latex.el b/font-latex.el
index 75502b5..6755f8d 100644
--- a/font-latex.el
+++ b/font-latex.el
@@ -500,7 +500,6 @@ the symbol TYPE.
This is a helper function for `font-latex-make-built-in-keywords'
and `font-latex-make-user-keywords' and not intended for general
use."
- ;; Note: The functions are byte-compiled at the end of font-latex.el.
;; FIXME: Is the cond-clause possible inside of the defun?
;; In an earlier version of font-latex the type could be a list like
@@ -621,18 +620,23 @@ Generated by `font-latex-make-built-in-keywords'."))
defs)
;; defvar font-latex-match-*
- (push `(defvar-local ,(intern (concat prefix name)) nil
+ ;; We make this variable buffer local later, but don't use
+ ;; `defvar-local' here because it shouldn't have nil as its
+ ;; default value. Its true default value is set by
+ ;; through font-latex-match-*-make in :set specification of
+ ;; defcustom of font-latex-match-*-keywords below. It's
+ ;; only after that this variable can be buffer local.
+ (push `(defvar ,(intern (concat prefix name)) nil
,(concat "Regular expression to match " name
" keywords.
Generated by `font-latex-make-built-in-keywords'"))
defs)
- ;; Put this
- ;; defvar font-latex-match-*-keywords
- ;; without value here just to suppress compiler
- ;; warnings. defcustom follows the next defun because its :set
- ;; function depends on the defun.
+ ;; This defvar (without value) is here just to suppress compiler
+ ;; warnings. Its true definition is done by defcustom following
+ ;; the next defun because its :set function depends on the
+ ;; function defined by that defun.
(push `(defvar ,(intern (concat prefix name "-keywords")))
defs)
@@ -695,6 +699,11 @@ Generated by `font-latex-make-built-in-keywords'.")
:group 'font-latex-keywords)
defs)
+ ;; Now that font-latex-match-* has attained proper default
+ ;; value, make it buffer local.
+ (push `(make-variable-buffer-local ',(intern (concat prefix name)))
+ defs)
+
;; defun font-latex-match-*
(push (font-latex--make-match-defun prefix name face type) defs)
- [elpa] externals/auctex updated (ce2ba8f -> 64e54ee), Tassilo Horn, 2021/03/25
- [elpa] externals/auctex 8f0638c 1/6: Fix merging, Tassilo Horn, 2021/03/25
- [elpa] externals/auctex adc70b8 4/6: Fix void function error, Tassilo Horn, 2021/03/25
- [elpa] externals/auctex 65a711b 2/6: Discard obsolete variables, Tassilo Horn, 2021/03/25
- [elpa] externals/auctex 6a47321 5/6: Fix font-latex.el,
Tassilo Horn <=
- [elpa] externals/auctex a7b5f1a 3/6: Fix documents, Tassilo Horn, 2021/03/25
- [elpa] externals/auctex 64e54ee 6/6: Merge branch 'master' into externals/auctex, Tassilo Horn, 2021/03/25