---@type vim.lsp.Config
svlangserver = {
cmd = { "svlangserver", "--stdio" },
root_markers = { ".git" },
filetypes = { "verilog", "systemverilog" },
settings = {
systemverilog = {
includeIndexing = { '*.{v,vh,sv,svh}', '**/*.{v,vh,sv,svh}' },
launchConfiguration = "xvlog -sv",
},
},
on_attach = function(client, bufnr)
vim.api.nvim_buf_create_user_command(bufnr, 'LspSvlangserverBuildIndex', function()
client:exec_cmd({
title = 'Build Index',
command = 'systemverilog.build_index',
}, { bufnr = bufnr })
end, {
desc = 'Instructs language server to rerun indexing',
})
vim.api.nvim_buf_create_user_command(bufnr, 'LspSvlangserverReportHierarchy', function()
client:exec_cmd({
title = 'Build Index',
command = 'systemverilog.build_index',
arguments = { vim.fn.expand '<cword>' },
}, { bufnr = bufnr })
end, {
desc = 'Generates hierarchy for the given module',
})
end,
}
No diagnostics are shown. However, keyword completion is working.
xvlog is in my path and is found in my nvim instance.
How can i use
xvlog -svfor linting systemverilog files using svlangserver?I tried this in Noevim v0.11.5:
No diagnostics are shown. However, keyword completion is working.
xvlogis in my path and is found in my nvim instance.