refactor(lua): improve type annotations

This commit is contained in:
Lewis Russell
2024-06-11 12:05:18 +01:00
committed by Lewis Russell
parent d8e384b7bf
commit 5e49ef0af3
20 changed files with 64 additions and 369 deletions

View File

@@ -121,6 +121,7 @@ function vim.stricmp(a, b) end
--- @param str string
--- @param index integer
--- @param use_utf16? boolean
--- @return integer
function vim.str_byteindex(str, index, use_utf16) end
--- Gets a list of the starting byte positions of each UTF-8 codepoint in the given string.

View File

@@ -34,6 +34,11 @@
--- @field filename? string
--- @field lnum integer
--- @class vim.fn.getmarklist.ret.item
--- @field mark string
--- @field pos [integer, integer, integer, integer]
--- @field file string
--- @class vim.fn.getmousepos.ret
--- @field screenrow integer
--- @field screencol integer

View File

@@ -3249,8 +3249,8 @@ function vim.fn.getloclist(nr, what) end
--- Refer to |getpos()| for getting information about a specific
--- mark.
---
--- @param buf? any
--- @return any
--- @param buf? integer?
--- @return vim.fn.getmarklist.ret.item[]
function vim.fn.getmarklist(buf) end
--- Returns a |List| with all matches previously defined for the