mirror of
https://github.com/neovim/neovim.git
synced 2025-09-06 19:38:20 +00:00
docs(vim.iter): correct bool
to boolean
(#27018)
This commit is contained in:
@@ -3753,9 +3753,9 @@ filter({f}, {src}, {...}) *vim.iter.filter()*
|
|||||||
<
|
<
|
||||||
|
|
||||||
Parameters: ~
|
Parameters: ~
|
||||||
• {f} (`fun(...):bool`) Filter function. Accepts the current iterator
|
• {f} (`fun(...):boolean`) Filter function. Accepts the current
|
||||||
or table values as arguments and returns true if those values
|
iterator or table values as arguments and returns true if those
|
||||||
should be kept in the final table
|
values should be kept in the final table
|
||||||
• {src} (`table|function`) Table or iterator function to filter
|
• {src} (`table|function`) Table or iterator function to filter
|
||||||
|
|
||||||
Return: ~
|
Return: ~
|
||||||
@@ -3768,7 +3768,7 @@ Iter:all({pred}) *Iter:all()*
|
|||||||
Returns true if all items in the iterator match the given predicate.
|
Returns true if all items in the iterator match the given predicate.
|
||||||
|
|
||||||
Parameters: ~
|
Parameters: ~
|
||||||
• {pred} (`fun(...):bool`) Predicate function. Takes all values
|
• {pred} (`fun(...):boolean`) Predicate function. Takes all values
|
||||||
returned from the previous stage in the pipeline as arguments
|
returned from the previous stage in the pipeline as arguments
|
||||||
and returns true if the predicate matches.
|
and returns true if the predicate matches.
|
||||||
|
|
||||||
@@ -3777,7 +3777,7 @@ Iter:any({pred}) *Iter:any()*
|
|||||||
predicate.
|
predicate.
|
||||||
|
|
||||||
Parameters: ~
|
Parameters: ~
|
||||||
• {pred} (`fun(...):bool`) Predicate function. Takes all values
|
• {pred} (`fun(...):boolean`) Predicate function. Takes all values
|
||||||
returned from the previous stage in the pipeline as arguments
|
returned from the previous stage in the pipeline as arguments
|
||||||
and returns true if the predicate matches.
|
and returns true if the predicate matches.
|
||||||
|
|
||||||
@@ -3826,7 +3826,7 @@ Iter:filter({f}) *Iter:filter()*
|
|||||||
<
|
<
|
||||||
|
|
||||||
Parameters: ~
|
Parameters: ~
|
||||||
• {f} (`fun(...):bool`) Takes all values returned from the previous
|
• {f} (`fun(...):boolean`) Takes all values returned from the previous
|
||||||
stage in the pipeline and returns false or nil if the current
|
stage in the pipeline and returns false or nil if the current
|
||||||
iterator element should be removed.
|
iterator element should be removed.
|
||||||
|
|
||||||
|
@@ -181,7 +181,7 @@ end
|
|||||||
--- local bufs = vim.iter(vim.api.nvim_list_bufs()):filter(vim.api.nvim_buf_is_loaded)
|
--- local bufs = vim.iter(vim.api.nvim_list_bufs()):filter(vim.api.nvim_buf_is_loaded)
|
||||||
--- ```
|
--- ```
|
||||||
---
|
---
|
||||||
---@param f fun(...):bool Takes all values returned from the previous stage
|
---@param f fun(...):boolean Takes all values returned from the previous stage
|
||||||
--- in the pipeline and returns false or nil if the
|
--- in the pipeline and returns false or nil if the
|
||||||
--- current iterator element should be removed.
|
--- current iterator element should be removed.
|
||||||
---@return Iter
|
---@return Iter
|
||||||
@@ -884,7 +884,7 @@ end
|
|||||||
|
|
||||||
--- Returns true if any of the items in the iterator match the given predicate.
|
--- Returns true if any of the items in the iterator match the given predicate.
|
||||||
---
|
---
|
||||||
---@param pred fun(...):bool Predicate function. Takes all values returned from the previous
|
---@param pred fun(...):boolean Predicate function. Takes all values returned from the previous
|
||||||
--- stage in the pipeline as arguments and returns true if the
|
--- stage in the pipeline as arguments and returns true if the
|
||||||
--- predicate matches.
|
--- predicate matches.
|
||||||
function Iter.any(self, pred)
|
function Iter.any(self, pred)
|
||||||
@@ -908,7 +908,7 @@ end
|
|||||||
|
|
||||||
--- Returns true if all items in the iterator match the given predicate.
|
--- Returns true if all items in the iterator match the given predicate.
|
||||||
---
|
---
|
||||||
---@param pred fun(...):bool Predicate function. Takes all values returned from the previous
|
---@param pred fun(...):boolean Predicate function. Takes all values returned from the previous
|
||||||
--- stage in the pipeline as arguments and returns true if the
|
--- stage in the pipeline as arguments and returns true if the
|
||||||
--- predicate matches.
|
--- predicate matches.
|
||||||
function Iter.all(self, pred)
|
function Iter.all(self, pred)
|
||||||
@@ -1106,7 +1106,7 @@ end
|
|||||||
---
|
---
|
||||||
---@see |Iter:filter()|
|
---@see |Iter:filter()|
|
||||||
---
|
---
|
||||||
---@param f fun(...):bool Filter function. Accepts the current iterator or table values as
|
---@param f fun(...):boolean Filter function. Accepts the current iterator or table values as
|
||||||
--- arguments and returns true if those values should be kept in the
|
--- arguments and returns true if those values should be kept in the
|
||||||
--- final table
|
--- final table
|
||||||
---@param src table|function Table or iterator function to filter
|
---@param src table|function Table or iterator function to filter
|
||||||
|
Reference in New Issue
Block a user