Sunday, April 15, 2012

Re: how to stop recursive maps in insert mode

sinbad <sinbad.sinbad@gmail.com> a écrit:
>
> i have following mappings.
>
> imap .. ->
> imap - _
>
> now when i type .. the text converts to _> instead of ->
> becuase of the second mapping for -, is there a way to
> stop this recursive expansion of maps.

Use ":inoremap .. ->" instead of "imap". All the "noremap" versions of
the mapping commands consider only the original "meaning" of the right
part.

Best,
Paul

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments: