fix(lsp): lint warnings, default offset_encoding #24046

- fix lint / analysis warnings
- locations_to_items(): get default offset_encoding from active client
- character_offset(): get default offset_encoding from active client
This commit is contained in:
Raphael
2023-07-01 18:42:37 +08:00
committed by GitHub
parent 11844dde81
commit ba8f19ebb6
7 changed files with 130 additions and 113 deletions

View File

@@ -36,7 +36,7 @@ end
local function parse_headers(header)
assert(type(header) == 'string', 'header must be a string')
local headers = {}
for line in vim.gsplit(header, '\r\n', true) do
for line in vim.gsplit(header, '\r\n', { plain = true }) do
if line == '' then
break
end