diff options
author | Björn Linse <bjorn.linse@gmail.com> | 2021-08-29 17:34:00 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-08-29 17:34:00 +0200 |
commit | 4e66e74fd7c6afb1813c40dd59f17091e546789d (patch) | |
tree | b4393cacfd5bfc8a4ebf3b1ba166eec83a8a9d9a /src/nvim/lua/vim.lua | |
parent | 81f4de08bdfeb4b9c107e2eaff3cbb597b2df943 (diff) | |
parent | 6896d22b63ad12de4c4990d0eece4a9b6f9cd88f (diff) | |
download | rneovim-4e66e74fd7c6afb1813c40dd59f17091e546789d.tar.gz rneovim-4e66e74fd7c6afb1813c40dd59f17091e546789d.tar.bz2 rneovim-4e66e74fd7c6afb1813c40dd59f17091e546789d.zip |
Merge pull request #15304 from bfredl/quantumtheory
fix(lua): preserve argument list ... which has not the same length as #{...}
Diffstat (limited to 'src/nvim/lua/vim.lua')
-rw-r--r-- | src/nvim/lua/vim.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/lua/vim.lua b/src/nvim/lua/vim.lua index ed435439a4..801226ab7b 100644 --- a/src/nvim/lua/vim.lua +++ b/src/nvim/lua/vim.lua @@ -273,8 +273,8 @@ end ---@see |vim.in_fast_event()| function vim.schedule_wrap(cb) return (function (...) - local args = {...} - vim.schedule(function() cb(unpack(args)) end) + local args = vim.F.pack_len(...) + vim.schedule(function() cb(vim.F.unpack_len(args)) end) end) end |