branch: master
commit 1d66dd1f6f047c05f0802b58c1924ec1f9700fd9
Author: Arash Esbati <ar...@gnu.org>
Commit: Arash Esbati <ar...@gnu.org>

    Enable lexical-binding in auto-generated styles
    
    * tex.el (TeX-auto-store): Add lexical cookie to auto-generated
    style files.
---
 tex.el | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tex.el b/tex.el
index cda1d7f6..0dec8568 100644
--- a/tex.el
+++ b/tex.el
@@ -4267,6 +4267,7 @@ If TEX is a directory, generate style files for all files 
in the directory."
         (TeX-unload-style style)
         (with-current-buffer (generate-new-buffer file)
           (erase-buffer)
+          (insert ";; -*- lexical-binding: t; -*-\n\n")
           (insert "(TeX-add-style-hook\n \""
                   style "\"\n (lambda ()")
           (unless (string= tex-cmd-opts "")

Reply via email to