------------------------------------------------------------ revno: 434 revision-id: monn...@iro.umontreal.ca-20130809215250-lqyfvls3iqfdbui9 parent: monn...@iro.umontreal.ca-20130809020004-wchassib8v7g6pcq committer: Stefan Monnier <monn...@iro.umontreal.ca> branch nick: elpa timestamp: Fri 2013-08-09 17:52:50 -0400 message: * packages/auctex/tex.el (TeX--call-3/2): New auxiliary function. (ConTeXt-Omega-engine, TeX-Omega-mode, TeX-source-specials-mode): Use it to provide the obsolescence version when possible. modified: packages/auctex/tex.el tex.el-20101118182351-xme90jru269t6msr-44
=== modified file 'packages/auctex/tex.el' --- a/packages/auctex/tex.el 2012-12-05 16:28:27 +0000 +++ b/packages/auctex/tex.el 2013-08-09 21:52:50 +0000 @@ -1,6 +1,6 @@ ;;; tex.el --- Support for TeX documents. -;; Copyright (C) 1985-1987, 1991, 1993, 1994, 1996, 1997, 1999-2012 +;; Copyright (C) 1985-1987, 1991, 1993, 1994, 1996, 1997, 1999-2013 ;; Free Software Foundation, Inc. ;; Maintainer: auctex-devel@gnu.org @@ -39,6 +39,11 @@ (eval-when-compile (require 'cl)) +(defun TeX--call-3/2 (f arg1 arg2 arg3) + (condition-case nil + (funcall f arg1 arg2 arg3) + (wrong-number-of-arguments (funcall f arg1 arg2)))) + (defgroup TeX-file nil "Files used by AUCTeX." :group 'AUCTeX) @@ -121,7 +126,8 @@ :type '(choice (const :tag "Unspecified" nil) string)) ;; At least in TeXLive 2009 ConTeXt does not support an omega option anymore. -(make-obsolete-variable 'ConTeXt-Omega-engine 'TeX-engine-alist) +(TeX--call-3/2 #'make-obsolete-variable 'ConTeXt-Omega-engine + 'TeX-engine-alist "before 11.86") (defcustom TeX-queue-command "lpq -P%p" "*Command used to show the status of a printer queue. @@ -1285,8 +1291,9 @@ :group 'TeX-command (TeX-engine-set (if TeX-Omega-mode 'omega 'default))) (defalias 'tex-omega-mode 'TeX-Omega-mode) -(make-obsolete 'TeX-Omega-mode 'TeX-engine-set) -(make-obsolete-variable 'TeX-Omega-mode 'TeX-engine) +(TeX--call-3/2 #'make-obsolete 'TeX-Omega-mode 'TeX-engine-set "before 11.86") +(TeX--call-3/2 #'make-obsolete-variable 'TeX-Omega-mode + 'TeX-engine "before 11.86") ;;; Forward and inverse search @@ -1434,7 +1441,8 @@ (when TeX-source-correlate-mode 'TeX-synctex-output-page)))) (defalias 'TeX-source-specials-mode 'TeX-source-correlate-mode) -(make-obsolete 'TeX-source-specials-mode 'TeX-source-correlate-mode) +(TeX--call-3/2 #'make-obsolete 'TeX-source-specials-mode + 'TeX-source-correlate-mode "before 11.86") (defalias 'tex-source-correlate-mode 'TeX-source-correlate-mode) (put 'TeX-source-correlate-mode 'safe-local-variable 'TeX-booleanp) ;; We do not want the custom variable to require tex.el. This is only
_______________________________________________ auctex-devel mailing list auctex-devel@gnu.org https://lists.gnu.org/mailman/listinfo/auctex-devel