diff options
| author | João Távora | 2025-09-03 08:15:38 +0100 |
|---|---|---|
| committer | João Távora | 2025-09-03 08:16:15 +0100 |
| commit | 5db70442e52c93f8bb8f6532a81d2cf4f30a7ad2 (patch) | |
| tree | 5927d908b964d57e3d192bc93d351615dfc159bd | |
| parent | 2b9c7f9508e435625c27d7b261f5ce6414d207f3 (diff) | |
| download | emacs-5db70442e52c93f8bb8f6532a81d2cf4f30a7ad2.tar.gz emacs-5db70442e52c93f8bb8f6532a81d2cf4f30a7ad2.zip | |
Eglot: really fix bug#79259
The previous change actually introduced a bug in a closely
related but distinct place. We need to address the off-by-one
in the 'substring' call, not the 'add-face-text-property'.
* lisp/progmodes/eglot.el (eglot--sig-info): Fixup.
| -rw-r--r-- | lisp/progmodes/eglot.el | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el index 475b5e13f1b..d06b97b431e 100644 --- a/lisp/progmodes/eglot.el +++ b/lisp/progmodes/eglot.el | |||
| @@ -3718,7 +3718,7 @@ for which LSP on-type-formatting should be requested." | |||
| 3718 | (let ((case-fold-search nil)) | 3718 | (let ((case-fold-search nil)) |
| 3719 | (and (search-forward parlabel (line-end-position) t) | 3719 | (and (search-forward parlabel (line-end-position) t) |
| 3720 | (list (match-beginning 0) (match-end 0)))) | 3720 | (list (match-beginning 0) (match-end 0)))) |
| 3721 | (list (aref parlabel 0) (aref parlabel 1))))) | 3721 | (list (1+ (aref parlabel 0)) (1+ (aref parlabel 1)))))) |
| 3722 | (if (and beg end) | 3722 | (if (and beg end) |
| 3723 | (add-face-text-property | 3723 | (add-face-text-property |
| 3724 | beg end | 3724 | beg end |
| @@ -3731,7 +3731,7 @@ for which LSP on-type-formatting should be requested." | |||
| 3731 | (insert "\n " | 3731 | (insert "\n " |
| 3732 | (propertize | 3732 | (propertize |
| 3733 | (if (stringp parlabel) parlabel | 3733 | (if (stringp parlabel) parlabel |
| 3734 | (apply #'substring siglabel (mapcar #'1+ parlabel))) | 3734 | (substring siglabel (aref parlabel 0) (aref parlabel 1))) |
| 3735 | 'face (and (eq i active-param) 'eldoc-highlight-function-argument)) | 3735 | 'face (and (eq i active-param) 'eldoc-highlight-function-argument)) |
| 3736 | ": " fpardoc))))) | 3736 | ": " fpardoc))))) |
| 3737 | (buffer-string)))) | 3737 | (buffer-string)))) |