davidpthomas schrieb:
> I have the following mapping setup:
> 
>  181     nmap <buffer> <Leader>k   <Plug>AccurevKeep
>  182     nnoremap <buffer> <script> <Plug>AccurevKeep <SID>Keep
>  183     nnoremap <buffer> <silent> <SID>Keep :call <SID>Keep()<CR>
> 
> I noticed if I ran the following nunmap *twice* in a row, both
> mappings at lines 181 and 182 become unmapped.  E.g.
> 
>  608   nunmap <buffer> <Plug>AccurevKeep
>  609   " test double unmap
>  610   nunmap <buffer> <Plug>AccurevKeep
> 
> I verified that 182 gets unmapped first as {lhs}, as expected.  I was
> surprised to see that 181 was even affected given that the nunmap
> pattern matched the {rhs}.
> 
> According to the docs, nunmap "Remove[s] the mapping of {lhs} for the
> modes where the map command applies.".   This seems a bit ambiguous
> and perhaps there is an order of precedence matching {lhs} first, then
> {rhs}?    Or should it only match {lhs}?
> 
> Thanks! - dave    (accurev plugin author)

Some convenience for abbreviations also "works" for mappings:

:h :una

Unmapping only happens when the {rhs} matches exactly.

-- 
Andy

--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Reply via email to