From 2cb9f0253228478ec27265ff40f59c629874d695 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Fri, 3 May 2019 15:13:57 +0200 Subject: patch 8.1.1251: no test for completion of mapping keys Problem: No test for completion of mapping keys. Solution: Add a test. Also clean up the code. --- src/getchar.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/getchar.c') diff --git a/src/getchar.c b/src/getchar.c index a1ffced14..776e4e684 100644 --- a/src/getchar.c +++ b/src/getchar.c @@ -4263,7 +4263,7 @@ set_context_in_map_cmd( } /* - * Find all mapping/abbreviation names that match regexp 'prog'. + * Find all mapping/abbreviation names that match regexp "regmatch"'. * For command line expansion of ":[un]map" and ":[un]abbrev" in all modes. * Return OK if matches found, FAIL otherwise. */ @@ -4343,7 +4343,7 @@ ExpandMappings( { if (mp->m_mode & expand_mapmodes) { - p = translate_mapping(mp->m_keys, TRUE); + p = translate_mapping(mp->m_keys); if (p != NULL && vim_regexec(regmatch, p, (colnr_T)0)) { if (round == 1) -- cgit v1.2.1