mirror of
https://github.com/neovim/neovim
synced 2025-07-15 08:41:47 +00:00
Problem: No type information for `vim.uv`. Solution: Vendor https://github.com/LuaCATS/luv (which is what luals bundles). This will allow other tooling to work out-of-the-box and make these files available to users and plugins without the need for `lazydev.nvim` etc.
33 lines
826 B
Lua
33 lines
826 B
Lua
---@meta
|
|
-- luacheck: no unused args
|
|
error('Cannot require a meta file')
|
|
|
|
--- Prepare handles will run the given callback once per loop iteration, right
|
|
--- before polling for I/O.
|
|
---
|
|
--- ```lua
|
|
--- local prepare = uv.new_prepare()
|
|
--- prepare:start(function()
|
|
--- print("Before I/O polling")
|
|
--- end)
|
|
--- ```
|
|
---
|
|
---@class uv.uv_prepare_t : uv.uv_handle_t
|
|
---
|
|
local prepare = {} -- luacheck: no unused
|
|
|
|
--- Start the handle with the given callback.
|
|
---
|
|
---@param callback function
|
|
---@return 0|nil success
|
|
---@return uv.error.message|nil err
|
|
---@return uv.error.name|nil err_name
|
|
function prepare:start(callback) end
|
|
|
|
--- Stop the handle, the callback will no longer be called.
|
|
---
|
|
---@return 0|nil success
|
|
---@return uv.error.message|nil err
|
|
---@return uv.error.name|nil err_name
|
|
function prepare:stop() end
|