aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/_editor.lua
diff options
context:
space:
mode:
authorLewis Russell <lewis6991@gmail.com>2023-06-03 11:06:00 +0100
committerGitHub <noreply@github.com>2023-06-03 12:06:00 +0200
commit2db719f6c2b677fcbc197b02fe52764a851523b2 (patch)
tree648885f655ea6eea2d6b5ad9409bc18c3b49e0f7 /runtime/lua/vim/_editor.lua
parentc65e2203f70cd5d66fcb8ffb26f8cef38f50e04f (diff)
downloadrneovim-2db719f6c2b677fcbc197b02fe52764a851523b2.tar.gz
rneovim-2db719f6c2b677fcbc197b02fe52764a851523b2.tar.bz2
rneovim-2db719f6c2b677fcbc197b02fe52764a851523b2.zip
feat(lua): rename vim.loop -> vim.uv (#22846)
Diffstat (limited to 'runtime/lua/vim/_editor.lua')
-rw-r--r--runtime/lua/vim/_editor.lua8
1 files changed, 6 insertions, 2 deletions
diff --git a/runtime/lua/vim/_editor.lua b/runtime/lua/vim/_editor.lua
index b26def5958..7b946a55e4 100644
--- a/runtime/lua/vim/_editor.lua
+++ b/runtime/lua/vim/_editor.lua
@@ -42,6 +42,10 @@ for k, v in pairs({
vim._submodules[k] = v
end
+-- Remove at Nvim 1.0
+---@deprecated
+vim.loop = vim.uv
+
-- There are things which have special rules in vim._init_packages
-- for legacy reasons (uri) or for performance (_inspector).
-- most new things should go into a submodule namespace ( vim.foobar.do_thing() )
@@ -159,7 +163,7 @@ do
--- - 3: ends the paste (exactly once)
---@returns boolean # false if client should cancel the paste.
function vim.paste(lines, phase)
- local now = vim.loop.now()
+ local now = vim.uv.now()
local is_first_chunk = phase < 2
local is_last_chunk = phase == -1 or phase == 3
if is_first_chunk then -- Reset flags.
@@ -483,7 +487,7 @@ end
---@return table timer luv timer object
function vim.defer_fn(fn, timeout)
vim.validate({ fn = { fn, 'c', true } })
- local timer = vim.loop.new_timer()
+ local timer = vim.uv.new_timer()
timer:start(
timeout,
0,