mirror of
https://github.com/neovim/neovim.git
synced 2026-04-25 00:35:36 +00:00
fix(options): vim.opt fails for 'fillchars' #37141
Problem:
When `to_vim_value[info.metatype](info, value)` is called, a list value
such as `{'eob:a'}` is treated like a map, which generates `1:eob:a`.
Note: commands like `:lua vim.opt.wildmode={'longest:full'}` are not an
issue because only cases harcoded in `key_value_options` have metatype `map`.
Solution:
Check for array type and use the same logic as in array metatypes.
This commit is contained in:
committed by
GitHub
parent
8f9278d7c2
commit
f4f1149292
@@ -435,6 +435,9 @@ local to_vim_value = {
|
||||
map = function(_, value)
|
||||
if type(value) == 'string' then
|
||||
return value
|
||||
elseif vim.isarray(value) then
|
||||
value = remove_duplicate_values(value)
|
||||
return table.concat(value, ',')
|
||||
end
|
||||
|
||||
local result = {}
|
||||
|
||||
Reference in New Issue
Block a user