Check Emacs version used for Tramp compilation
* lisp/net/tramp-compat.el (tramp-compat-emacs-compiled-version): New defconst. Raise a warning, when it is not equal to the Emacs version.
This commit is contained in:
parent
90e5549f02
commit
8fbaca7d41
1 changed files with 8 additions and 0 deletions
|
@ -44,6 +44,14 @@
|
|||
;; `temporary-file-directory' as function is introduced with Emacs 26.1.
|
||||
(declare-function tramp-handle-temporary-file-directory "tramp")
|
||||
|
||||
(defconst tramp-compat-emacs-compiled-version (eval-when-compile emacs-version)
|
||||
"The Emacs version used for compilation.")
|
||||
|
||||
(unless (= emacs-major-version
|
||||
(car (version-to-list tramp-compat-emacs-compiled-version)))
|
||||
(warn "Tramp has been compiled with Emacs %s, this is Emacs %s"
|
||||
tramp-compat-emacs-compiled-version emacs-version))
|
||||
|
||||
;; For not existing functions, obsolete functions, or functions with a
|
||||
;; changed argument list, there are compiler warnings. We want to
|
||||
;; avoid them in cases we know what we do.
|
||||
|
|
Loading…
Add table
Reference in a new issue