aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZyX <kp-pav@yandex.ru>2017-05-20 05:02:03 +0300
committerZyX <kp-pav@yandex.ru>2017-05-20 05:02:03 +0300
commite14f678689c172e0307546dfae2358e76c54fec4 (patch)
treeab3b823447ce3e3bba48bbc797a821dc24e09979
parenta052040430a3272e50975f7797839dde005b3be4 (diff)
downloadrneovim-e14f678689c172e0307546dfae2358e76c54fec4.tar.gz
rneovim-e14f678689c172e0307546dfae2358e76c54fec4.tar.bz2
rneovim-e14f678689c172e0307546dfae2358e76c54fec4.zip
options: Silence V542 without using comments
-rw-r--r--src/nvim/generators/gen_options.lua3
-rw-r--r--src/nvim/options.lua7
2 files changed, 7 insertions, 3 deletions
diff --git a/src/nvim/generators/gen_options.lua b/src/nvim/generators/gen_options.lua
index bf829582e0..ca0134043c 100644
--- a/src/nvim/generators/gen_options.lua
+++ b/src/nvim/generators/gen_options.lua
@@ -118,8 +118,7 @@ local get_value = function(v)
end
local get_defaults = function(d)
- return ('{' .. get_value(d.vi) .. '/* -V542 */, '
- .. get_value(d.vim) .. '/* -V542 */}')
+ return ('{' .. get_value(d.vi) .. ', ' .. get_value(d.vim) .. '}')
end
local defines = {}
diff --git a/src/nvim/options.lua b/src/nvim/options.lua
index 6ad0501f0a..c2778a6329 100644
--- a/src/nvim/options.lua
+++ b/src/nvim/options.lua
@@ -34,6 +34,11 @@ local macros=function(s)
return s
end
end
+local imacros=function(s)
+ return function()
+ return '(intptr_t)' .. s
+ end
+end
local N_=function(s)
return function()
return 'N_(' .. cstr(s) .. ')'
@@ -2648,7 +2653,7 @@ return {
type='number', scope={'global'},
vim=true,
varname='p_wc',
- defaults={if_true={vi=macros('Ctrl_E'), vim=macros('TAB')}}
+ defaults={if_true={vi=imacros('Ctrl_E'), vim=imacros('TAB')}}
},
{
full_name='wildcharm', abbreviation='wcm',