mirror of
https://github.com/neovim/neovim.git
synced 2025-10-21 17:21:49 +00:00
Lua: vim.env, vim.{g,v,w,bo,wo} #11442
- Add vim variable meta accessors: vim.env, vim.{g,v,w,bo,wo} - Redo gen_char_blob to generate multiple blobs instead of just one so that multiple Lua modules can be inlined. - Reorder vim.lua inclusion so that it can use previously defined C functions and utility functions like vim.shared and vim.inspect things. - Inline shared.lua into nvim, but also keep it available in runtime.
This commit is contained in:

committed by
Justin M. Keyes

parent
222637c341
commit
d0d38fc36e
@@ -99,6 +99,9 @@ function module.pcall_err(fn, ...)
|
||||
-- to this:
|
||||
-- Error executing lua: .../foo.lua:186: Expected string, got number
|
||||
errmsg = errmsg:gsub([[lua: [a-zA-Z]?:?[^:]-[/\]([^:/\]+):%d+: ]], 'lua: .../%1: ')
|
||||
-- Compiled modules will not have a path and will just be a name like
|
||||
-- shared.lua:186, so strip the number.
|
||||
errmsg = errmsg:gsub([[lua: ([^:/\ ]+):%d+: ]], 'lua: .../%1: ')
|
||||
-- ^ Windows drive-letter (C:)
|
||||
return errmsg
|
||||
end
|
||||
|
Reference in New Issue
Block a user