auctex-diffs
[Top][All Lists]
Advanced

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

[AUCTeX-diffs] [elpa] externals/auctex 235f93c 46/67: ; Silence the comp


From: Tassilo Horn
Subject: [AUCTeX-diffs] [elpa] externals/auctex 235f93c 46/67: ; Silence the compiler in styles for pstricks
Date: Fri, 8 Feb 2019 11:40:38 -0500 (EST)

branch: externals/auctex
commit 235f93c452453aae42566fb92ec5ea0feba187d2
Author: Arash Esbati <address@hidden>
Commit: Arash Esbati <address@hidden>

    ; Silence the compiler in styles for pstricks
    
    * style/pst-grad.el:
    * style/pst-slpe.el: Silence the compiler for the free variables
    `LaTeX-pst-fillstyle-list',
    `LaTeX-pst-parameters-completion-regexp' and
    `LaTeX-pst-parameters-name-list'.
    
    * style/pst-node.el: Silence the compiler for the functions
    `LaTeX-package-parameter-value',
    `LaTeX-package-parameters-pref-and-chosen',
    `LaTeX-package-parameters', `LaTeX-pst-angle', `LaTeX-pst-point'
    and `LaTeX-pst-arrows'.
    
    * style/pst-plot.el: Silence the compiler for the free variable
    `LaTeX-pstplot-datasets' by rearranging code.
    Silence the compiler for the functions free variables
    `LaTeX-pst-arrows', `LaTeX-pst-point', `TeX-arg-compl-list' and
    free variables `LaTeX-pst-parameters-completion-regexp' and
    `LaTeX-pst-parameters-name-list'.
---
 style/pst-grad.el |  5 +++++
 style/pst-node.el | 11 +++++++++++
 style/pst-plot.el | 57 ++++++++++++++++++++++++++++++++-----------------------
 style/pst-slpe.el |  5 +++++
 4 files changed, 54 insertions(+), 24 deletions(-)

diff --git a/style/pst-grad.el b/style/pst-grad.el
index 1e74d8a..829e190 100644
--- a/style/pst-grad.el
+++ b/style/pst-grad.el
@@ -33,6 +33,11 @@
 
 ;;; Code:
 
+;; Silence the compiler:
+(defvar LaTeX-pst-fillstyle-list)
+(defvar LaTeX-pst-parameters-completion-regexp)
+(defvar LaTeX-pst-parameters-name-list)
+
 ;;; Parameters
 (defvar LaTeX-pstgrad-parameters-name-list
   '("gradangle" "gradbegin" "gradend" "gradlines" "gradmidpoint"
diff --git a/style/pst-node.el b/style/pst-node.el
index cc6b151..7b174cd 100644
--- a/style/pst-node.el
+++ b/style/pst-node.el
@@ -35,6 +35,17 @@
 
 ;;; Code:
 
+;; Silence the compiler:
+(declare-function LaTeX-package-parameter-value
+                 "pstricks" (param pname))
+(declare-function LaTeX-package-parameters-pref-and-chosen
+                 "pstricks" (param pname noskip))
+(declare-function LaTeX-package-parameters
+                 "pstricks" (optional pname preparam param))
+(declare-function LaTeX-pst-angle  "pstricks" ())
+(declare-function LaTeX-pst-point  "pstricks" ())
+(declare-function LaTeX-pst-arrows "pstricks" ())
+
 (defalias 'LaTeX-pst-node 'LaTeX-pst-point)
 
 (defvar LaTeX-pstnode-parameters-completion-regexp
diff --git a/style/pst-plot.el b/style/pst-plot.el
index 2d61d88..8240a14 100644
--- a/style/pst-plot.el
+++ b/style/pst-plot.el
@@ -35,31 +35,14 @@
 
 ;;; Code:
 
-;; Self Parsing -- see (info "(auctex)Hacking the Parser")
-(defvar LaTeX-auto-pstplot-regexp-list
-  '(("\\\(save\|read\)data{?\(\\[a-zA-Z]+\)}?"
-     2 LaTeX-auto-pstplot))
-  "List of regular expressions to extract arguments of \*data
-  macros.")
+;; Silence the compiler:
+(declare-function LaTeX-pst-arrows "pstricks" ())
+(declare-function LaTeX-pst-point  "pstricks" ())
+(declare-function TeX-arg-compl-list
+                 "pstricks" (list &optional prompt hist))
 
-(defvar LaTeX-auto-pstplot nil
-  "Temporary for parsing \*data definitions.")
-
-(defun LaTeX-pstplot-cleanup ()
-  "Move symbols from `LaTeX-auto-pstplot to `TeX-auto-symbol'."
-  (mapcar (lambda (symbol)
-            ;; (setq TeX-symbol-list (cons (list symbol 0) TeX-symbol-list))
-            ;; (setq TeX-auto-symbol (cons (list symbol 0) TeX-auto-symbol)))
-            (add-to-list 'LaTeX-pstplot-datasets symbol))
-            LaTeX-auto-pstplot))
-
-(defun LaTeX-pstplot-prepare ()
-  "Clear `LaTeX-auto-pstplot' before use."
-  (setq LaTeX-auto-pstplot nil))
-
-(add-hook 'TeX-auto-prepare-hook #'LaTeX-pstplot-prepare t)
-(add-hook 'TeX-auto-cleanup-hook #'LaTeX-pstplot-cleanup t)
-(add-hook 'TeX-update-style-hook #'TeX-auto-parse t)
+(defvar LaTeX-pst-parameters-completion-regexp)
+(defvar LaTeX-pst-parameters-name-list)
 
 ;;; Parameters
 (defvar LaTeX-pstplot-datasets nil
@@ -85,6 +68,32 @@
 (defvar LaTeX-pst-axesstyle-list '(t "axes" "frame" "none")
   "A list of values for axesstyles in pst-plot.")
 
+;; Self Parsing -- see (info "(auctex)Hacking the Parser")
+(defvar LaTeX-auto-pstplot-regexp-list
+  '(("\\\(save\|read\)data{?\(\\[a-zA-Z]+\)}?"
+     2 LaTeX-auto-pstplot))
+  "List of regular expressions to extract arguments of \*data
+  macros.")
+
+(defvar LaTeX-auto-pstplot nil
+  "Temporary for parsing \*data definitions.")
+
+(defun LaTeX-pstplot-cleanup ()
+  "Move symbols from `LaTeX-auto-pstplot to `TeX-auto-symbol'."
+  (mapcar (lambda (symbol)
+            ;; (setq TeX-symbol-list (cons (list symbol 0) TeX-symbol-list))
+            ;; (setq TeX-auto-symbol (cons (list symbol 0) TeX-auto-symbol)))
+            (add-to-list 'LaTeX-pstplot-datasets symbol))
+            LaTeX-auto-pstplot))
+
+(defun LaTeX-pstplot-prepare ()
+  "Clear `LaTeX-auto-pstplot' before use."
+  (setq LaTeX-auto-pstplot nil))
+
+(add-hook 'TeX-auto-prepare-hook #'LaTeX-pstplot-prepare t)
+(add-hook 'TeX-auto-cleanup-hook #'LaTeX-pstplot-cleanup t)
+(add-hook 'TeX-update-style-hook #'TeX-auto-parse t)
+
 ;;; Macros
 (defun LaTeX-pst-macro-psaxes (_optional &optional _arg)
   "Return \psaxes arguments after querying."
diff --git a/style/pst-slpe.el b/style/pst-slpe.el
index a3f456f..6efed09 100644
--- a/style/pst-slpe.el
+++ b/style/pst-slpe.el
@@ -33,6 +33,11 @@
 
 ;;; Code:
 
+;; Silence the compiler:
+(defvar LaTeX-pst-fillstyle-list)
+(defvar LaTeX-pst-parameters-completion-regexp)
+(defvar LaTeX-pst-parameters-name-list)
+
 ;;; Parameters
 (defvar LaTeX-pstslpe-parameters-name-list
   '("slopeangle" "slopecenter" "slopecolors" "slopebegin" "slopeend"



reply via email to

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