aboutsummaryrefslogtreecommitdiff
path: root/plugin/toggle_option_flags.vim
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2018-07-19 21:50:17 +1200
committerTom Ryder <tom@sanctum.geek.nz>2018-07-19 21:51:02 +1200
commit5bf9da3dcbb8bacd437ba287949deaf9c9b7f098 (patch)
tree401d60581e21c228ede1a80b742ec82873a54449 /plugin/toggle_option_flags.vim
parentRename README.md (diff)
downloadvim-toggle-flags-5bf9da3dcbb8bacd437ba287949deaf9c9b7f098.tar.gz
vim-toggle-flags-5bf9da3dcbb8bacd437ba287949deaf9c9b7f098.zip
Correct a few comments
Diffstat (limited to 'plugin/toggle_option_flags.vim')
-rw-r--r--plugin/toggle_option_flags.vim5
1 files changed, 2 insertions, 3 deletions
diff --git a/plugin/toggle_option_flags.vim b/plugin/toggle_option_flags.vim
index 4021dd0..49142ed 100644
--- a/plugin/toggle_option_flags.vim
+++ b/plugin/toggle_option_flags.vim
@@ -25,7 +25,6 @@ endfunction
function! s:Has(option, flag)
" Horrible :execute to get the option's current setting into a variable
- " (I couldn't get {curly braces} indirection to work)
let l:current = ''
execute 'let l:current = &' . a:option
@@ -41,7 +40,7 @@ function! s:Has(option, flag)
let l:search_value = l:current
endif
- " Return whether
+ " Return whether the flag appears in the value
return stridx(l:search_value, l:search_flag) > -1
endfunction
@@ -90,7 +89,7 @@ function! s:Toggle(option, flag, local)
call s:Error('Unable to toggle '.a:option.' flag '.a:flag)
endif
- " Return value is whether we made a change
+ " Return whether we made a change
return l:before != l:after
endfunction