mirror of
https://github.com/neovim/neovim.git
synced 2025-12-16 03:15:39 +00:00
refactor: move vim.lsp.diagnostic to vim.diagnostic
This generalizes diagnostic handling outside of just the scope of LSP. LSP clients are now a specific case of a diagnostic producer, but the diagnostic subsystem is decoupled from the LSP subsystem (or will be, eventually). More discussion at [1]. [1]: https://github.com/neovim/neovim/pull/15585
This commit is contained in:
@@ -210,10 +210,16 @@ local function response_to_list(map_result, entity)
|
||||
else
|
||||
config = config or {}
|
||||
if config.loclist then
|
||||
util.set_loclist(map_result(result, ctx.bufnr))
|
||||
vim.fn.setloclist(0, {}, ' ', {
|
||||
title = 'Language Server';
|
||||
items = map_result(result, ctx.bufnr);
|
||||
})
|
||||
api.nvim_command("lopen")
|
||||
else
|
||||
util.set_qflist(map_result(result, ctx.bufnr))
|
||||
vim.fn.setqflist({}, ' ', {
|
||||
title = 'Language Server';
|
||||
items = map_result(result, ctx.bufnr);
|
||||
})
|
||||
api.nvim_command("copen")
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user