mirror of
https://github.com/vim/vim.git
synced 2025-09-26 04:04:07 -04:00
patch 8.2.4504: when there is a partially matching map full map may not work
Problem: When there is a partially matching map and modifyOtherKeys is active a full map may not work. Solution: Only simplify modifiers when there is no matching mapping. (closes #8792)
This commit is contained in:
@@ -2598,7 +2598,7 @@ handle_mapping(
|
||||
}
|
||||
|
||||
// If no partly match found, use the longest full match.
|
||||
if (keylen != KEYLEN_PART_MAP)
|
||||
if (keylen != KEYLEN_PART_MAP && mp_match != NULL)
|
||||
{
|
||||
mp = mp_match;
|
||||
keylen = mp_match_len;
|
||||
@@ -2643,7 +2643,7 @@ handle_mapping(
|
||||
max_mlen = mlen + 1;
|
||||
}
|
||||
|
||||
if ((mp == NULL || max_mlen >= mp_match_len) && keylen != KEYLEN_PART_MAP)
|
||||
if ((mp == NULL || max_mlen > mp_match_len) && keylen != KEYLEN_PART_MAP)
|
||||
{
|
||||
int save_keylen = keylen;
|
||||
|
||||
|
Reference in New Issue
Block a user