Loading ...
Sorry, an error occurred while loading the content.

54930Re: 'l' breaks macro when run at the end of line

Expand Messages
  • Andy Wokula
    Sep 10, 2009
    • 0 Attachment
      Milan Vancura schrieb:
      >> Lech Lorens schrieb:
      >>> BTW unlike documentation e.g. for :global or :tabdo, documentation for
      >>> @ does not mention the expected behaviour if an error is encountered.
      >>> IMHO this means that errors should be ignored.
      >> Macros and mappings are quite similar in this regard
      >> :h macro
      >> /error
      >> | Note that when an error is encountered (that causes an error message or beep)
      >> | the rest of the mapping is not executed. This is Vi-compatible.
      > Sure. The only problem is that, in case I pointed out, the error throwing is
      > not consistent: '99l' run on the previous-to-last char of the line does NOT
      > throw the error while even simple 'l' run on the last char of the DOES.
      > Milan

      consistency depends on the point of view ...

      I think the rule is simple:
      If a motion command cannot move the cursor, you will get a beep (otherwise not).

      In the example, 99l moves the cursor -> no beep.


      You received this message from the "vim_dev" maillist.
      For more information, visit http://www.vim.org/maillist.php
    • Show all 13 messages in this topic