fix(lsp): vim.Range check in document_color.color_presentation() (#38374)

Problem:
`vim.lsp.document_color.color_presentation()` throws, due to incorrect use of the `vim.Range` API.

Solution:
Change `vim.Range.has(a, b)` call to `a:has(b)`.
This commit is contained in:
mpal9000
2026-03-19 19:00:45 +02:00
committed by GitHub
parent b927ee2c48
commit 4b0700c618

View File

@@ -306,7 +306,7 @@ local function get_hl_info_under_cursor(provider)
for client_id, state in pairs(provider.client_state) do
for _, hl in ipairs(state.hl_info) do
if vim.Range.has(hl.range, cursor_pos) then
if hl.range:has(cursor_pos) then
return hl, client_id
end
end