mirror of
https://github.com/neovim/neovim.git
synced 2026-09-12 17:11:02 +00:00
build: enable more EmmyLua checks
- call-non-callable - missing-fields - redefined-label - redefined-local - undefined-field - unreachable-code Promote redefined-local and unreachable-code to warnings. Fix DOS line-ending handling for multiline semantic tokens, and support intersection types in the help parser. AI-assisted
This commit is contained in:
committed by
Lewis Russell
parent
ec65796cea
commit
6a54396db4
@@ -345,8 +345,8 @@ function M.offset(buf, offset)
|
||||
|
||||
local lnum = vim.list.bisect(
|
||||
setmetatable({}, {
|
||||
__index = function(_, lnum)
|
||||
return api.nvim_buf_get_offset(buf, lnum - 1)
|
||||
__index = function(_, idx)
|
||||
return api.nvim_buf_get_offset(buf, idx - 1)
|
||||
end,
|
||||
}),
|
||||
offset,
|
||||
@@ -364,6 +364,6 @@ setmetatable(M, {
|
||||
return M.new(...)
|
||||
end,
|
||||
})
|
||||
---@cast M +fun(buf: integer, row: integer, col: integer): vim.Pos
|
||||
---@cast M vim.Pos & fun(buf: integer, row: integer, col: integer): vim.Pos
|
||||
|
||||
return M
|
||||
|
||||
Reference in New Issue
Block a user