Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Question] LSP hover information and dependencies navigation functionalities #87

Open
pidgeon777 opened this issue Jan 26, 2021 · 1 comment

Comments

@pidgeon777
Copy link

As a language server, HDL Checker will provide

1 - Diagnostics
2 - Hover information

  • Dependencies: will report which path and library have been assigned
  • Design units: will report the compilation sequence and libraries

3 - Go to definition of dependencies

How would it be possible to make use of features 2 and 3 in Vim or similar (for example, Neovim)?

Best regards

@bramhooimeijer
Copy link
Contributor

bramhooimeijer commented Jan 14, 2022

Depends on how HDL checker is integrated (Ale/lspconfig/coc etc).

E.g., for lspconfig, the following configuration is recommended in the lspconfig readme:

buf_set_keymap('n', 'gD', '<cmd>lua vim.lsp.buf.declaration()<CR>', opts)
buf_set_keymap('n', 'gd', '<cmd>lua vim.lsp.buf.definition()<CR>', opts)
buf_set_keymap('n', 'K', '<cmd>lua vim.lsp.buf.hover()<CR>', opts)

That would allow hover with 'K' and go to definition with 'gd'. For e.g. VHDL, this works when hovering over the entity name in an instantiation.

Coc, ale and others have their own commands listed in their respective readmes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants