summaryrefslogtreecommitdiff
path: root/plugin/vdebug.vim
diff options
context:
space:
mode:
authorDudemullet <elpaip@gmail.com>2015-12-13 00:56:43 -0600
committerDudemullet <elpaip@gmail.com>2015-12-13 00:56:43 -0600
commit49552f52c3452747817d61f36625ed80c2a809e7 (patch)
tree26dea8d3e2ac87d8cee1cd75e523796a65177ae5 /plugin/vdebug.vim
parent10c1f33b1c5459a2908bf54a480a7b409c3c0903 (diff)
downloadvdebug-49552f52c3452747817d61f36625ed80c2a809e7.zip
Moves g:vdebug_options_ to a variables and gets its len for later use
Diffstat (limited to 'plugin/vdebug.vim')
-rw-r--r--plugin/vdebug.vim5
1 files changed, 3 insertions, 2 deletions
diff --git a/plugin/vdebug.vim b/plugin/vdebug.vim
index 3988cc9..59d0ab4 100644
--- a/plugin/vdebug.vim
+++ b/plugin/vdebug.vim
@@ -164,13 +164,14 @@ function! Vdebug_load_options(options)
" Merge options with defaults
let param_namespace = "g:vdebug_options_"
- let parameters = map(keys(g:vdebug_options_defaults), '"g:vdebug_options_".v:val')
+ let param_namespace_len = strlen(param_namespace)
+ let parameters = map(keys(g:vdebug_options_defaults), 'param_namespace.v:val')
let existing_params = filter(parameters, 'exists(v:val)')
let final_params = {}
for name in existing_params
let val = eval(name)
- let name = strpart(name, 17)
+ let name = strpart(name, param_namespace_len)
let final_params[name] = val
endfor