Documentation fix for repeat#setreg()
Need to :execute the :silent! call to avoid that the remainder of the command line is aborted together with the call when repeat.vim is not installed. Otherwise, <SID>MyFunction() won't be invoked, and the mapping does nothing.
This commit is contained in:
parent
eb97e729be
commit
5974ea07ac
@ -40,7 +40,7 @@
|
|||||||
" in your mapping will look like this:
|
" in your mapping will look like this:
|
||||||
"
|
"
|
||||||
" nnoremap <silent> <Plug>MyMap
|
" nnoremap <silent> <Plug>MyMap
|
||||||
" \ :<C-U>silent! call repeat#setreg("\<lt>Plug>MyMap", v:register)<Bar>
|
" \ :<C-U>execute 'silent! call repeat#setreg("\<lt>Plug>MyMap", v:register)'<Bar>
|
||||||
" \ call <SID>MyFunction(v:register, ...)<Bar>
|
" \ call <SID>MyFunction(v:register, ...)<Bar>
|
||||||
" \ silent! call repeat#set("\<lt>Plug>MyMap")<CR>
|
" \ silent! call repeat#set("\<lt>Plug>MyMap")<CR>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user