From 7454d201895f1b52e04c7a406fde211f4b00e878 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0t=C4=9Bp=C3=A1n=20N=C4=9Bmec?= Date: Wed, 4 Mar 2020 08:24:13 +0100 Subject: [PATCH] org-eldoc: Use eldoc-documentation-functions when available This reflects recent changes in GNU Emacs master branch: 2020-02-25T17:53:04-05:00!mvoteiza@udel.edu c0fcbd2c11 (Expose ElDoc functions in a hook (Bug#28257)) * lisp/org-eldoc.el (org-eldoc-load): Use 'eldoc-documentation-functions' when available. --- contrib/lisp/org-eldoc.el | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/contrib/lisp/org-eldoc.el b/contrib/lisp/org-eldoc.el index b4fc0c866..72b10a1fb 100644 --- a/contrib/lisp/org-eldoc.el +++ b/contrib/lisp/org-eldoc.el @@ -161,7 +161,11 @@ (defun org-eldoc-load () "Set up org-eldoc documentation function." (interactive) - (setq-local eldoc-documentation-function #'org-eldoc-documentation-function)) + (if (boundp 'eldoc-documentation-functions) + (add-hook 'eldoc-documentation-functions + #'org-eldoc-documentation-function nil t) + (setq-local eldoc-documentation-function + #'org-eldoc-documentation-function))) ;;;###autoload (add-hook 'org-mode-hook #'org-eldoc-load)