1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-11-22 07:09:54 +00:00

Fix 'shortdoc-copy-function-as-kill'

* lisp/emacs-lisp/shortdoc.el (shortdoc-copy-function-as-kill):
Fix handling of functions with no arguments.  (Bug#69720)
This commit is contained in:
Eli Zaretskii 2024-03-16 13:07:52 +02:00
parent d5901f3f05
commit 8cf05d9be1

View File

@ -1675,7 +1675,7 @@ With prefix numeric argument ARG, do it that many times."
(interactive)
(save-excursion
(goto-char (pos-bol))
(when-let* ((re (rx bol "(" (group (+ (not (in " "))))))
(when-let* ((re (rx bol "(" (group (+ (not (in " )"))))))
(string
(and (or (looking-at re)
(re-search-backward re nil t))