From: Bram Moolenaar Date: Fri, 10 Jul 2015 15:19:30 +0000 (+0200) Subject: patch 7.4.773 X-Git-Tag: v7.4.773 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=ae94b7718ab5ecc820ce487c9ea0178c04a9853c;p=vim patch 7.4.773 Problem: 'langmap' is used in command-line mode when checking for mappings. Issue 376. Solution: Do not use 'langmap' in command-line mode. (Larry Velazquez) --- diff --git a/src/getchar.c b/src/getchar.c index 54bce315f..a80432fc5 100644 --- a/src/getchar.c +++ b/src/getchar.c @@ -2145,7 +2145,8 @@ vgetorpeek(advance) nolmaplen = 2; else { - LANGMAP_ADJUST(c1, (State & INSERT) == 0); + LANGMAP_ADJUST(c1, + (State & (CMDLINE | INSERT)) == 0); nolmaplen = 0; } #endif diff --git a/src/testdir/test_mapping.in b/src/testdir/test_mapping.in index 979184394..d6c1b2d5d 100644 --- a/src/testdir/test_mapping.in +++ b/src/testdir/test_mapping.in @@ -28,9 +28,18 @@ GV :inoremap { FAIL_ilangmap :set langmap=+{ langnoremap o+ -: " expr mapping with langmap +:" Insert-mode expr mapping with langmap :inoremap { "FAIL_iexplangmap" o+ +:" langmap should not get remapped in Command-line mode +:cnoremap { FAIL_clangmap +:call append(line('$'), '+') +:cunmap { +:" Command-line mode expr mapping with langmap +:cnoremap { "FAIL_cexplangmap" +:call append(line('$'), '+') +:cunmap { +:" :" issue #212 (feedkeys insert mapping at current position) :nnoremap . :call feedkeys(".", "in") :/^a b diff --git a/src/testdir/test_mapping.ok b/src/testdir/test_mapping.ok index 6a88f02de..51cc49bf7 100644 --- a/src/testdir/test_mapping.ok +++ b/src/testdir/test_mapping.ok @@ -8,3 +8,5 @@ TEST2: CTRL-C |A| vmap works + + ++ ++ diff --git a/src/version.c b/src/version.c index a43046e9e..8ab862ac4 100644 --- a/src/version.c +++ b/src/version.c @@ -741,6 +741,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 773, /**/ 772, /**/