Replies: 2 comments 1 reply
-
i just realized treesitter can also be usd for this purpose. and it'd be much easier to implement since i can access the AST rather than parsing the response of textDocument/hover. there is one already: https://github.com/danymat/neogen |
Beta Was this translation helpful? Give feedback.
0 replies
-
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi folks!
It is often boring and inefficient to write signature anonations for functions from scratch, since language server already knew the signature infomation about a function, and it uses a dedicated anonation flavor, it must be capable to generate these anonations for us.
But the problem is there is no such method in the LSP spec, at least i failed to find one.
In practical, lua-language-server's
textDocument/hover
givesfunction foo(a: any, b: any) -> number
for this code.(If this feature can not be provided on the langserver side, i think i can make a plugin for nvim, and actually i am just about to do it)
Beta Was this translation helpful? Give feedback.
All reactions