aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/_editor.lua
diff options
context:
space:
mode:
authorLewis Russell <lewis6991@gmail.com>2023-11-21 11:24:30 +0000
committerLewis Russell <me@lewisr.dev>2023-11-27 09:09:21 +0000
commit84bbe4b0ca935db1f6202db339aee5594a3b3908 (patch)
treef71a1a2d3ab75f1b1deece31065e80c46b1b842e /runtime/lua/vim/_editor.lua
parent6343d414369de1f3b259e51438cd4f666d82d3d2 (diff)
downloadrneovim-84bbe4b0ca935db1f6202db339aee5594a3b3908.tar.gz
rneovim-84bbe4b0ca935db1f6202db339aee5594a3b3908.tar.bz2
rneovim-84bbe4b0ca935db1f6202db339aee5594a3b3908.zip
fix(lua): disallow vim.wait() in fast contexts
`vim.wait()` cannot be called in a fast callback since the main loop cannot be run in that context as it is not reentrant Fixes #26122
Diffstat (limited to 'runtime/lua/vim/_editor.lua')
-rw-r--r--runtime/lua/vim/_editor.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/runtime/lua/vim/_editor.lua b/runtime/lua/vim/_editor.lua
index 12b632075d..6cccbe8313 100644
--- a/runtime/lua/vim/_editor.lua
+++ b/runtime/lua/vim/_editor.lua
@@ -124,7 +124,8 @@ vim.log = {
--- @return vim.SystemObj Object with the fields:
--- - pid (integer) Process ID
--- - wait (fun(timeout: integer|nil): SystemCompleted) Wait for the process to complete. Upon
---- timeout the process is sent the KILL signal (9) and the exit code is set to 124.
+--- timeout the process is sent the KILL signal (9) and the exit code is set to 124. Cannot
+--- be called in |api-fast|.
--- - SystemCompleted is an object with the fields:
--- - code: (integer)
--- - signal: (integer)