auctex-diffs
[Top][All Lists]
Advanced

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

[AUCTeX-diffs] GNU AUCTeX branch, master, updated. 6a47321fcea175158aff8


From: Ikumi Keita
Subject: [AUCTeX-diffs] GNU AUCTeX branch, master, updated. 6a47321fcea175158aff810826307f4ea8388c6d
Date: Thu, 25 Mar 2021 09:02:58 -0400 (EDT)

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU AUCTeX".

The branch, master has been updated
       via  6a47321fcea175158aff810826307f4ea8388c6d (commit)
      from  adc70b81d1e9c955da7436930be5a73775bedca3 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 6a47321fcea175158aff810826307f4ea8388c6d
Author: Ikumi Keita <ikumi@ikumi.que.jp>
Date:   Thu Mar 25 21:57:47 2021 +0900

    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.

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)
 

-----------------------------------------------------------------------

Summary of changes:
 font-latex.el | 23 ++++++++++++++++-------
 1 file changed, 16 insertions(+), 7 deletions(-)


hooks/post-receive
-- 
GNU AUCTeX



reply via email to

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