No Wayman writes: > Subject: [PATCH] org-eldoc: (org-eldoc-documentation-function): set > `eldoc-documentation-functions' > > * contrib/lisp/org-eldoc.el (org-eldoc-documentation-function): > > b2b587387 did not set eldoc-documentation-functions, resulting in > `eldoc--invoke-strategy' throwing a void-fucntion error.
I'll plan to drop the unconventional blank line in the changelog entry and s/fucntion/function/ when applying. > --- > contrib/lisp/org-eldoc.el | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/contrib/lisp/org-eldoc.el b/contrib/lisp/org-eldoc.el > index aa1dcb41b..ce0b7ddc2 100644 > --- a/contrib/lisp/org-eldoc.el > +++ b/contrib/lisp/org-eldoc.el > @@ -138,7 +138,8 @@ > (string= lang "emacs-lisp") > (string= lang "elisp")) (if (fboundp > 'elisp-eldoc-documentation-function) > (elisp-eldoc-documentation-function) > - (let (eldoc-documentation-function) > + (let ((eldoc-documentation-functions > + '(elisp-eldoc-var-docstring > elisp-eldoc-funcall))) > (eldoc-print-current-symbol-info)))) > ((or > (string= lang "c") ;; http://github.com/nflath/c-eldoc This works on my end testing with Emacs 26.3 and the Emacs master branch. For example #+begin_src elisp (message "ok") #+end_src shows "message: (FORMAT-STRING &rest ARGS)" when point is positioned after "message". I don't have Emacs 24 at hand, but the eldoc-documentation-function let-binding you're dropping should be retained for it, I think. Assuming it's fine with you, I'll squash this into your patch. diff --git a/contrib/lisp/org-eldoc.el b/contrib/lisp/org-eldoc.el index ce0b7ddc2..3b0999340 100644 --- a/contrib/lisp/org-eldoc.el +++ b/contrib/lisp/org-eldoc.el @@ -136,11 +136,16 @@ (defun org-eldoc-documentation-function (&rest _ignored) (let ((lang (org-eldoc-get-src-lang))) (cond ((or (string= lang "emacs-lisp") - (string= lang "elisp")) (if (fboundp 'elisp-eldoc-documentation-function) - (elisp-eldoc-documentation-function) - (let ((eldoc-documentation-functions - '(elisp-eldoc-var-docstring elisp-eldoc-funcall))) - (eldoc-print-current-symbol-info)))) + (string= lang "elisp")) + (cond ((boundp 'eldoc-documentation-functions) ; Emacs>=28 + (let ((eldoc-documentation-functions + '(elisp-eldoc-var-docstring elisp-eldoc-funcall))) + (eldoc-print-current-symbol-info))) + ((fboundp 'elisp-eldoc-documentation-function) + (elisp-eldoc-documentation-function)) + (t ; Emacs<25 + (let (eldoc-documentation-function) + (eldoc-print-current-symbol-info))))) ((or (string= lang "c") ;; http://github.com/nflath/c-eldoc (string= lang "C")) (when (require 'c-eldoc nil t)