docs(iter): add emmylua type to iter module (#23845)

This commit is contained in:
Sebastian Lyng Johansen
2023-06-03 09:18:05 +02:00
committed by GitHub
parent a8ee4c7a81
commit c65e2203f7

View File

@@ -51,6 +51,8 @@
--- In addition to the |vim.iter()| function, the |vim.iter| module provides --- In addition to the |vim.iter()| function, the |vim.iter| module provides
--- convenience functions like |vim.iter.filter()| and |vim.iter.totable()|. --- convenience functions like |vim.iter.filter()| and |vim.iter.totable()|.
---@class IterMod
---@operator call:Iter
local M = {} local M = {}
---@class Iter ---@class Iter
@@ -974,6 +976,7 @@ function M.map(f, src, ...)
return Iter.new(src, ...):map(f):totable() return Iter.new(src, ...):map(f):totable()
end end
---@type IterMod
return setmetatable(M, { return setmetatable(M, {
__call = function(_, ...) __call = function(_, ...)
return Iter.new(...) return Iter.new(...)