-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 19-Feb-2015 23:55, Alexey wrote:
> Hello, i wonder if the following is a bug or a feature.
> 
> If execute the commands
> 
> :imap 2 3 :inoremap 13 42
> 
> and type "12" in Insert mode, i get "13", but i would naïvely
> expect to get "42".

No, that's correct. When you type "1", Vim recognizes that the "13"
mapping may apply, and waits for the next key. As this is "2", that
mapping doesn't apply. (The ":imap" doesn't get in between, and no
potential right-hand side has been produced yet; it's all still in
limbo.) There are no other candidates, so the "1" is cleared for use,
and only the current "2" is of concern. That one is mapped to "3",
yielding "13".

- -- regards, ingo
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (MingW32)

iQEcBAEBAgAGBQJU5v8pAAoJEA7ziXlAzQ/v0iEH/35Nv+vLypfqD7sP5nM0vW2B
nE8QnUUwow+8HUQ+GKjA5FpE/esDGeoGMZE1oDhCpdGoB73RNPnXRSe1S/jODpIS
fsijLJ0s5wYbVtBECrON1jd6evNAa0nsHtcqKLm12ehdO3tyAeEIdASw0TM1p/4E
GHy8IshGMh81LWco/jMcUykHeZjQgn/sGuC0srl8GARzAKoRz5s04MFt1SXAXaAJ
ozWezB1rRnu4PjqQiIW69ImTKskM/d3rfG4pLdO4aQ4j0C9KzpzW/9McSdRWxf9e
OEsDjSBWyDL/7cTI29P8YLfVJZvnpq/wTerpGUU/EDKlgI3MRiJN/FDfhOPNEcE=
=gJKS
-----END PGP SIGNATURE-----

-- 
-- 
You received this message from the "vim_dev" 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

--- 
You received this message because you are subscribed to the Google Groups 
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to vim_dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to