LSP: hover range of use
statement is too big
#3578
XeroOl
started this conversation in
Ideas & suggestions
Replies: 1 comment
-
This is the intended behaviour. If we changed this how would you know what the function returns. Not this is not specific to use and is how all function call hovering works in Gleam. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have the following code in the file
example.gleam
.When I hover over the text
// hello
, I expect to get no results, because I'm hovering over a comment.However, I get a response of
Result(Nil, a)
, which doesn't make sense.The
use
statement is necessary to reproduce the bug; The issue happens to all text after a use statement within the same block.I suspect that the issue is that the compiler considers the
use
statement to span from theuse
keyword all the way to the end of the block, covering all the text in between.gleam 1.4.1
Arch Linux
Erlang runtime
NVIM v0.10.1, if the specific LSP client matters.
gleam_lsp_trace.log
Beta Was this translation helpful? Give feedback.
All reactions