Merge pull request #14730 from mjlbach/feature/open_loclist_on_win

fix(lsp): set_loclist should target current win
This commit is contained in:
Michael Lingelbach
2021-06-05 17:12:55 -07:00
committed by GitHub
2 changed files with 5 additions and 3 deletions

View File

@@ -1602,8 +1602,8 @@ end
--- Can be obtained with e.g. |vim.lsp.util.locations_to_items()|.
---
--@param items (table) list of items
function M.set_loclist(items)
vim.fn.setloclist(0, {}, ' ', {
function M.set_loclist(items, win_id)
vim.fn.setloclist(win_id or 0, {}, ' ', {
title = 'Language Server';
items = items;
})