Shoosh warnings about obsolete eldoc-documentation-function

* lisp/progmodes/cfengine.el (cfengine3-mode): Remove mention to
obsolete eldoc-documentation-function.

* lisp/progmodes/python.el (python-mode): Use with-no-warnings.
This commit is contained in:
João Távora 2020-07-08 20:20:14 +01:00
parent a85026c3af
commit 6063b542f7
2 changed files with 12 additions and 17 deletions

View file

@ -5553,14 +5553,16 @@ REPORT-FN is Flymake's callback function."
(current-column))))
(^ '(- (1+ (current-indentation))))))
(if (null eldoc-documentation-function)
;; Emacs<25
(set (make-local-variable 'eldoc-documentation-function)
#'python-eldoc-function)
(if (boundp 'eldoc-documentation-functions)
(add-hook 'eldoc-documentation-functions #'python-eldoc-function nil t)
(add-function :before-until (local 'eldoc-documentation-function)
#'python-eldoc-function)))
(with-no-warnings
;; supress warnings about eldoc-documentation-function being obsolete
(if (null eldoc-documentation-function)
;; Emacs<25
(set (make-local-variable 'eldoc-documentation-function)
#'python-eldoc-function)
(if (boundp 'eldoc-documentation-functions)
(add-hook 'eldoc-documentation-functions #'python-eldoc-function nil t)
(add-function :before-until (local 'eldoc-documentation-function)
#'python-eldoc-function))))
(add-to-list
'hs-special-modes-alist