Subject: bug#61812: closed (Re: 30.0.50; Eglot inlay hints "pile up")

From: [email-masked] (GNU bug Tracking System)
Date: Mon, 27 Feb 2023 14:32:02 +0000

Your bug report

#61812: 30.0.50; Eglot inlay hints "pile up"

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to [email-masked].

-- 
61812: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=61812
GNU Bug Tracking System
Contact [email-masked] with problems

Subject: Re: 30.0.50; Eglot inlay hints "pile up"
From: João Távora <[email-masked]>
To: Chinmay Dalal <[email-masked]>
Cc: [email-masked]
Date: Mon, 27 Feb 2023 14:33:07 +0000
List-Id: <debbugs-submit.debbugs.gnu.org>

Chinmay Dalal <[email-masked]> writes:

> Chinmay Dalal <[email-masked]> writes:
>
>> Eglot inlay hints pile up when scrolling a large file.
>> To reproduce
>> 1) Open a large rust file with rust-analyzer installed
>>   (I tried to reproduce this with C++/clangd but I couldn't, maybe
>>   because it has less no. of hints)
>> 2) Scroll around
>> 3) Look for duplicate hints

I've reproduced this.  This is rust-analyzer's fault.  We ask it for
hints in some region, and it happily returns hints outside that.

Reported this in https://github.com/rust-lang/rust-analyzer/issues/14215

   (:jsonrpc "2.0" :id 216 :method "textDocument/inlayHint" :params
             (:textDocument
              (:uri "file:///home/capitaomorte/Source/Rust/bevy/crates/bevy_animation/src/lib.rs")
              :range
              (:start
               (:line 187 :character 0)
               :end
               (:line 238 :character 31))))
   [server-reply] (id:216) Mon Feb 27 14:11:25 2023:
   (:jsonrpc "2.0" :id 216 :result
             [(:position
               (:line 294 :character 1)
               :label
               [(:value "fn animation_player" :location
                        (:uri "file:///home/capitaomorte/Source/Rust/bevy/crates/bevy_animation/src/lib.rs" :range
                              (:start
                               (:line 185 :character 7)
                               :end
                               (:line 185 :character 23))))]

Easy to fix on Eglot's side though, so pushed a fix to emacs-29 and closing.

João

Subject: 30.0.50; Eglot inlay hints "pile up"
From: Chinmay Dalal <[email-masked]>
To: [email-masked]
Date: Sun, 26 Feb 2023 17:54:08 +0530
List-Id: <debbugs-submit.debbugs.gnu.org>

Eglot inlay hints pile up when scrolling a large file.
To reproduce
1) Open a large rust file with rust-analyzer installed
  (I tried to reproduce this with C++/clangd but I couldn't, maybe
  because it has less no. of hints)
2) Scroll around
3) Look for duplicate hints

Screenshots attached

In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version
 3.24.36, cairo version 1.17.8) of 2023-02-26 built on ganymede
Repository revision: 8797e514ab68c12ed05d3af88e6baba64bf08f4d
Repository branch: master
System Description: Arch Linux

Configured using:
 'configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib
 --localstatedir=/var --mandir=/usr/share/man --with-gameuser=:games
 --with-modules --without-libotf --without-m17n-flt --without-gconf
 --enable-autodepend --with-native-compilation=yes
 --with-native-compilation=aot --with-xinput2 --with-pgtk
 --without-xaw3d --with-sound=no --with-xwidgets --with-tree-sitter
 --without-compress-install
 '--program-transform-name=s/\([ec]tags\)/\1.emacs/'
 'CFLAGS=-march=native -mtune=native -O2 -pipe -fno-plt -fexceptions
 -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security
 -fstack-clash-protection -fcf-protection -fuse-ld=mold -ftree-vectorize
 -fuse-ld=mold -ftree-vectorize'
 LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now'

Configured features:
ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG
JSON LCMS2 LIBSYSTEMD LIBXML2 MODULES NATIVE_COMP NOTIFY INOTIFY PDUMPER
PGTK PNG RSVG SECCOMP SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS
TREE_SITTER WEBP XIM XWIDGETS GTK3 ZLIB

Important settings:
  value of $LANG: en_IN.UTF-8
  locale-coding-system: utf-8-unix

Major mode: Lisp Interaction

Minor modes in effect:
  server-mode: t
  parinfer-rust-mode: t
  elisp-autofmt-mode: t
  doom-modeline-mode: t
  minions-mode: t
  global-anzu-mode: t
  anzu-mode: t
  global-git-gutter-mode: t
  pdf-occur-global-minor-mode: t
  darkman-mode: t
  shell-dirtrack-mode: t
  global-flycheck-eglot-mode: t
  org-super-agenda-mode: t
  corfu-popupinfo-mode: t
  global-corfu-mode: t
  corfu-mode: t
  marginalia-mode: t
  savehist-mode: t
  vertico-mode: t
  yas-global-mode: t
  yas-minor-mode: t
  global-ligature-mode: t
  ligature-mode: t
  global-ts-fold-mode: t
  global-origami-mode: t
  origami-mode: t
  global-tree-sitter-mode: t
  which-key-mode: t
  override-global-mode: t
  global-undo-tree-mode: t
  undo-tree-mode: t
  evil-goggles-mode: t
  global-evil-surround-mode: t
  evil-surround-mode: t
  evil-commentary-mode: t
  global-evil-collection-unimpaired-mode: t
  evil-collection-unimpaired-mode: t
  evil-mode: t
  evil-local-mode: t
  windmove-mode: t
  global-flycheck-mode: t
  flycheck-mode: t
  recentf-mode: t
  hl-line-mode: t
  display-line-numbers-mode: t
  straight-use-package-mode: t
  straight-package-neutering-mode: t
  save-place-mode: t
  tooltip-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  show-paren-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  line-number-mode: t
  transient-mark-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t

Load-path shadows:
/home/chinmay/.local/state/emacs/straight/build/emacsql-sqlite/emacsql-sqlite hides /home/chinmay/.local/state/emacs/straight/build/emacsql/emacsql-sqlite
/home/chinmay/.local/state/emacs/straight/build/transient/transient hides /usr/share/emacs/30.0.50/lisp/transient
/home/chinmay/.local/state/emacs/straight/build/bind-key/bind-key hides /usr/share/emacs/30.0.50/lisp/use-package/bind-key
/home/chinmay/.local/state/emacs/straight/build/use-package/use-package-ensure hides /usr/share/emacs/30.0.50/lisp/use-package/use-package-ensure
/home/chinmay/.local/state/emacs/straight/build/use-package/use-package hides /usr/share/emacs/30.0.50/lisp/use-package/use-package
/home/chinmay/.local/state/emacs/straight/build/use-package/use-package-delight hides /usr/share/emacs/30.0.50/lisp/use-package/use-package-delight
/home/chinmay/.local/state/emacs/straight/build/use-package/use-package-core hides /usr/share/emacs/30.0.50/lisp/use-package/use-package-core
/home/chinmay/.local/state/emacs/straight/build/use-package/use-package-diminish hides /usr/share/emacs/30.0.50/lisp/use-package/use-package-diminish
/home/chinmay/.local/state/emacs/straight/build/use-package/use-package-lint hides /usr/share/emacs/30.0.50/lisp/use-package/use-package-lint
/home/chinmay/.local/state/emacs/straight/build/use-package/use-package-bind-key hides /usr/share/emacs/30.0.50/lisp/use-package/use-package-bind-key
/home/chinmay/.local/state/emacs/straight/build/use-package/use-package-jump hides /usr/share/emacs/30.0.50/lisp/use-package/use-package-jump
/home/chinmay/.local/state/emacs/straight/build/xref/xref hides /usr/share/emacs/30.0.50/lisp/progmodes/xref
/usr/share/emacs/site-lisp/xscheme hides /usr/share/emacs/30.0.50/lisp/progmodes/xscheme
/home/chinmay/.local/state/emacs/straight/build/project/project hides /usr/share/emacs/30.0.50/lisp/progmodes/project
/home/chinmay/.local/state/emacs/straight/build/let-alist/let-alist hides /usr/share/emacs/30.0.50/lisp/emacs-lisp/let-alist

Features:
(shadow emacsbug tramp-cmds cc-mode cc-fonts cc-guess cc-menus cc-cmds
cape-yasnippet cape find-dired evil-collection-grep grep vc-hg vc-bzr
conf-mode tramp-sh tramp-cache time-stamp tramp tramp-loaddefs trampver
tramp-integration cus-start files-x tramp-compat ls-lisp
evil-collection-helpful helpful cc-langs trace evil-collection-edebug
edebug info-look help-fns evil-collection-elisp-refs elisp-refs affe
mm-archive sort gnus-cite mail-extr textsec uni-scripts idna-mapping
ucs-normalize uni-confusable textsec-check qp misearch multi-isearch
find-file elec-pair evil-collection-vc-git vc-git
evil-collection-diff-mode diff-mode vc-dispatcher face-remap cdlatex
evil-collection-reftex reftex-toc reftex-cite reftex-ref reftex-parse
reftex reftex-loaddefs reftex-vars org-fragtog org-modern org-block-capf
evil-org-agenda evil-org oc-basic disp-table ol-eww evil-collection-eww
eww url-queue mm-url ol-rmail ol-mhe ol-irc ol-info ol-gnus nnselect
ol-docview evil-collection-doc-view doc-view ol-bibtex bibtex ol-bbdb
ol-w3m ol-doi org-link-doi server parinfer-rust-mode
parinfer-rust-changes parinfer-rust parinfer-rust-helper elisp-autofmt
loadhist eldoc-box doom-modeline doom-modeline-segments
doom-modeline-env doom-modeline-core shrink-path eldoc-box-autoloads
devdocs-autoloads ace-window-autoloads avy-autoloads
elisp-autofmt-autoloads doom-modeline-autoloads shrink-path-autoloads
minions minions-autoloads mu-config evil-collection-mu4e mu4e mu4e-org
mu4e-main mu4e-view gnus-art mm-uu mml2015 mm-view mml-smime smime
gnutls dig gnus-sum gnus-group gnus-undo gnus-start gnus-dbus gnus-cloud
nnimap nnmail mail-source utf7 nnoo parse-time iso8601 gnus-spec
gnus-int gnus-range gnus-win evil-collection-gnus gnus nnheader range
mu4e-headers mu4e-compose mu4e-draft mu4e-actions smtpmail mu4e-search
mu4e-lists mu4e-bookmarks mu4e-mark mu4e-message shr pixel-fill kinsoku
url-file svg dom flow-fill mule-util mu4e-contacts mu4e-update
mu4e-folders mu4e-server mu4e-context mu4e-obsolete mu4e-vars
mu4e-helpers mu4e-config ido message sendmail yank-media rfc822 mml
mml-sec evil-collection-epa epa derived epg rfc6068 epg-config gnus-util
mm-decode mm-bodies mm-encode mailabbrev mail-utils gmm-utils mailheader
auth-source-pass run-command-conf run-command-autoloads helm-make
helm-make-autoloads geiser-guile-autoloads geiser-autoloads evil-anzu
evil-anzu-autoloads anzu anzu-autoloads git-gutter-fringe git-gutter
git-gutter-fringe-autoloads git-gutter-autoloads org-noter
org-noter-autoloads pdf-occur ibuf-ext evil-collection-ibuffer ibuffer
ibuffer-loaddefs evil-collection-tablist tablist tablist-filter
semantic/wisent/comp semantic/wisent semantic/wisent/wisent
semantic/util-modes semantic/util semantic semantic/tag semantic/lex
semantic/fw mode-local cedet pdf-isearch let-alist pdf-misc pdf-loader
evil-collection-pdf pdf-history pdf-tools evil-collection-package-menu
package browse-url url-handlers evil-collection-custom cus-edit cus-load
pdf-view jka-compr pdf-cache pdf-info tq pdf-util pdf-macs
pdf-tools-autoloads tablist-autoloads modus-vivendi-theme darkman dbus
xml darkman-autoloads fennel-mode fennel-eldoc inf-lisp shell
fennel-mode-autoloads kbd-mode kbd-mode-autoloads fish-mode
fish-mode-autoloads elfeed-config elfeed-autoloads vterm-autoloads
modus-themes modus-themes-autoloads eglot-config consult-eglot
evil-collection-consult consult-vertico consult evil-collection-bookmark
bookmark eglot-x flycheck-eglot evil-collection-eglot eglot
external-completion array filenotify jsonrpc evil-collection-ert ert
ewoc evil-collection-debug debug backtrace evil-collection-flymake
flymake-proc flymake evil-collection-imenu imenu consult-eglot-autoloads
eglot-x-autoloads flycheck-eglot-autoloads rustic-flycheck
rustic-spellcheck rustic-expand rustic-lsp rustic-playground
rustic-rustfix rustic-racer etags fileloop evil-collection-xref xref
rustic-babel rustic-rustfmt project rustic-comint rustic-clippy
rustic-doc f f-shortdoc rustic-popup rustic-cargo rustic-compile spinner
xterm-color evil-collection-markdown-mode markdown-mode
rustic-interaction rustic rust-utils rust-mode rustic-autoloads
xterm-color-autoloads spinner-autoloads project-autoloads xref-autoloads
markdown-mode-autoloads rust-mode-autoloads org-config
org-super-agenda-conf org-super-agenda ts ht org-habit
org-super-agenda-autoloads ts-autoloads ht-autoloads evil-org-autoloads
org-block-capf-autoloads org-download org-attach ox-odt rng-loc rng-uri
rng-parse rng-match rng-dt rng-util rng-pttrn nxml-parse nxml-ns
nxml-enc xmltok nxml-util ox-latex ox-icalendar org-agenda ox-html table
ox-ascii ox-publish ox org-element org-persist xdg org-id org-refile
avl-tree generator evil-collection-org org ob ob-tangle ob-ref ob-lob
ob-table ob-exp org-macro org-src ob-comint org-pcomplete pcomplete
org-list org-footnote org-faces org-entities evil-collection-outline
noutline outline ob-emacs-lisp ob-core ob-eval org-cycle org-table ol
org-fold org-fold-core org-keys oc org-loaddefs evil-collection-calendar
cal-menu calendar cal-loaddefs org-version org-compat org-macs
format-spec url-http url-auth mail-parse rfc2231 rfc2047 rfc2045 mm-util
ietf-drums mail-prsvr url-gw nsm puny async org-download-autoloads
async-autoloads org-modern-autoloads org-roam-autoloads
emacsql-sqlite-autoloads emacsql-autoloads org-fragtog-autoloads
cdlatex-autoloads auctex-autoloads tex-site affe-autoloads corfu-config
cape-yasnippet-autoloads cape-autoloads corfu-terminal popon
corfu-terminal-autoloads popon-autoloads corfu-popupinfo
evil-collection-corfu corfu corfu-autoloads minibuffer-config
embark-consult-autoloads marginalia marginalia-autoloads savehist
vertico-directory evil-collection-vertico vertico vertico-autoloads
orderless-config orderless orderless-autoloads yasnippet
yasnippet-autoloads helpful-autoloads elisp-refs-autoloads f-autoloads
exec-path-from-shell exec-path-from-shell-autoloads ligature
ligature-autoloads ts-fold-indicators fringe-helper ts-fold
ts-fold-summary ts-fold-parsers ts-fold-util ts-fold-autoloads
fringe-helper-autoloads origami origami-parsers cl s origami-autoloads
s-autoloads evil-textobj-tree-sitter evil-textobj-tree-sitter-autoloads
tree-sitter-langs tree-sitter-langs-build evil-collection-tar-mode
tar-mode evil-collection-arc-mode arc-mode archive-mode url url-proxy
url-privacy url-expand url-methods url-history url-cookie url-domsuf
url-util url-parse auth-source eieio eieio-core password-cache url-vars
mailcap pp tree-sitter-hl tree-sitter tree-sitter-load tree-sitter-cli
tsc tsc-dyn tsc-dyn-get evil-collection-compile compile
text-property-search evil-collection-comint comint ansi-osc dired-aux
tsc-obsolete tree-sitter-langs-autoloads tree-sitter-autoloads
tsc-autoloads parinfer-rust-mode-autoloads evil-collection-which-key
which-key which-key-autoloads embark-autoloads use-package-bind-key
bind-key git-link-autoloads magit-autoloads magit-section-autoloads
git-commit-autoloads with-editor-autoloads transient-autoloads general
general-autoloads undo-tree diff queue undo-tree-autoloads
queue-autoloads evil-goggles pulse color evil-goggles-autoloads
evil-surround evil-surround-autoloads evil-commentary
evil-commentary-integration evil-commentary-autoloads
evil-collection-unimpaired evil-collection-tabulated-list
evil-collection-tab-bar evil-collection-simple evil-collection-replace
evil-collection-process-menu evil-collection-info evil-collection-indent
evil-collection-image image-mode evil-collection-dired dired
dired-loaddefs exif evil-collection-help evil-collection-flycheck
evil-collection-elisp-mode evil-collection-eldoc calc-ext
evil-collection-calc evil-collection-buff-menu evil-collection annalist
evil-collection-autoloads annalist-autoloads evil evil-integration
evil-maps evil-commands reveal evil-jumps evil-command-window
evil-search evil-ex evil-types evil-macros evil-repeat evil-states
evil-core time-date advice evil-common windmove calc calc-loaddefs
calc-macs thingatpt rect evil-digraphs evil-vars ring edmacro kmacro
evil-autoloads goto-chg-autoloads consult-flycheck-autoloads
consult-autoloads flycheck ansi-color json map find-func dash
flycheck-autoloads let-alist-autoloads pkg-info-autoloads epl-autoloads
dash-autoloads all-the-icons all-the-icons-faces data-material
data-weathericons data-octicons data-fileicons data-faicons
data-alltheicons all-the-icons-autoloads recentf tree-widget wid-edit
no-littering compat no-littering-autoloads compat-autoloads finder-inf
use-package-ensure use-package-core use-package-autoloads
bind-key-autoloads straight-autoloads comp comp-cstr warnings icons rx
hl-line display-line-numbers cl-extra help-mode straight info
loaddefs-gen generate-lisp-file lisp-mnt radix-tree easy-mmode cl-seq
pcase subr-x byte-opt cl-macs gv bytecomp byte-compile saveplace
llvm-style cc-styles cc-align cc-engine cc-vars cc-defs cl-loaddefs
cl-lib rmc iso-transl tooltip cconv eldoc paren electric uniquify
ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/pgtk-win
pgtk-win term/common-win pgtk-dnd tool-bar dnd fontset image regexp-opt
fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode
register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select
scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors
frame minibuffer nadvice seq simple cl-generic indonesian philippine
cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao
korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech
european ethiopic indian cyrillic chinese composite emoji-zwj charscript
charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure
cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp
files window text-properties overlay sha1 md5 base64 format env
code-pages mule custom widget keymap hashtable-print-readable backquote
threads xwidget-internal dbusbind inotify dynamic-setting
system-font-setting font-render-setting cairo gtk pgtk lcms2 multi-tty
make-network-process native-compile emacs)

Memory information:
((conses 16 1253548 695557)
 (symbols 48 62868 287)
 (strings 32 281589 96177)
 (string-bytes 1 10088683)
 (vectors 16 174668)
 (vector-slots 8 3697752 1320252)
 (floats 8 2036 8440)
 (intervals 56 20936 19674)
 (buffers 984 53))