2009/10/28 anna <annaklein...@gmail.com>: > > Hi, > > I found error "E16:Invalid range". This is how to reproduce it. > > :function! Foo() > :echo "foo" > :endfunction > :nmap x :call Foo()<CR> > > If I input "x" or "2x" in normal mode, it behaves as expected, > echoing "foo". However, if input "3x" or greater range, then it throws > me error E16:Invalid range".
when you press a number before the map key , the function will be called as follow 1x :.call Foo() 2x :.,.+1call Foo() 3x :.,.+2call Foo() and , so on so , if the range specified before the function is out-of-range , the E16 would be shown. > > Any advice why this could happen? > Thank you > > Anna > > > --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_use" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---