bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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


From: João Távora
Subject: bug#61812: 30.0.50; Eglot inlay hints "pile up"
Date: Mon, 27 Feb 2023 14:33:07 +0000
User-agent: Gnus/5.13 (Gnus v5.13)

Chinmay Dalal <dalal.chinmay.0101@gmail.com> writes:

> Chinmay Dalal <dalal.chinmay.0101@gmail.com> 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





reply via email to

[Prev in Thread] Current Thread [Next in Thread]