File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -103,9 +103,10 @@ Results are meaningful only if FROM and TO are on the same line."
103103 " Find or create a lens for the line at POS."
104104 (-doto (save-excursion
105105 (goto-char pos)
106- (if (eq 'end-of-line lsp-lens-place-position)
107- (make-overlay (line-end-position ) -1 nil t t )
108- (make-overlay (line-beginning-position ) (1+ (line-end-position )) nil t t )))
106+ (let ((eol (line-end-position )))
107+ (if (eq 'end-of-line lsp-lens-place-position)
108+ (make-overlay eol eol nil t t )
109+ (make-overlay (line-beginning-position ) (1+ eol) nil t t ))))
109110 (overlay-put 'lsp-lens t )
110111 (overlay-put 'lsp-lens-position pos)))
111112
Original file line number Diff line number Diff line change @@ -862,6 +862,6 @@ line 3 words here and here
862862 (should (string-match-p " My command"
863863 (overlay-get (car lenses) 'after-string )))
864864 (goto-char (overlay-start (car lenses)))
865- (should (equal (line-number-at-pos ) (- line 1 )))))))
865+ (should (equal (line-number-at-pos ) (+ line 1 )))))))
866866
867867; ;; lsp-mock-server-test.el ends here
You can’t perform that action at this time.
0 commit comments