Implement lsp-references support in the GDScript language server #3687
Description
Describe the project you are working on
I don't know if this matters here, but I'm just playing around with Godot doing several different small projects to just have some fun with the editor.
Describe the problem or limitation you are having in your project
For my scripting needs I use Nvim with nvim-lsp, since that is the script editor I'm the most comfortable with. With others LSP, I can quickly bring up a list with references that shows me where something is used (also when it is called in parent or child scripts.). This is a really nice function to have in an LSP since I can quickly see where something is used and find all locations of it.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
Something I'm missing from the LSP in Godot is the ability to be able to call "vim.lsp.buf.references()". When calling that command over a variable or function it brings up a list where this function or varible is used / called.
The
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
- This is an example how it looks with Telescope in NVIM using the "Omnisharp" server.
Again, I would just like the implementation of "vim.lsp.buf.references()", and when I say that, I don't mean it should be tied to VIM. From my limited understanding of LanguageServers, it is something that the different servers need to support and it works with whichever editor you use that supports LSP and can call this.
If this enhancement will not be used often, can it be worked around with a few lines of script?
I have not found a work-around for this.
Is there a reason why this should be core and not an add-on in the asset library?
This would need to be part of the Godot Language Server as I have understood it.
Activity