diff --git a/src/edit.c b/src/edit.c index f064b3b65f..0c7a9d1ef5 100644 --- a/src/edit.c +++ b/src/edit.c @@ -10242,9 +10242,9 @@ ins_eol(int c) int i; if (echeck_abbr(c + ABBR_OFF)) - return FALSE; + return OK; if (stop_arrow() == FAIL) - return TRUE; + return FAIL; undisplay_dollar(); /* diff --git a/src/testdir/test_mapping.vim b/src/testdir/test_mapping.vim index 5026d6b2bb..79863c4da9 100644 --- a/src/testdir/test_mapping.vim +++ b/src/testdir/test_mapping.vim @@ -198,3 +198,19 @@ func Test_map_timeout() set timeoutlen& delfunc ExitInsert endfunc + +func Test_abbreviation_CR() + new + func Eatchar(pat) + let c = nr2char(getchar(0)) + return (c =~ a:pat) ? '' : c + endfunc + iabbrev ~~7 =repeat('~', 7)=Eatchar('\s') + call feedkeys("GA~~7 \", 'xt') + call assert_equal('~~~~~~~', getline('$')) + %d + call feedkeys("GA~~7\\", 'xt') + call assert_equal(['~~~~~~~', ''], getline(1,'$')) + delfunc Eatchar + bw! +endfunc diff --git a/src/version.c b/src/version.c index e953667a05..73a4b9eaca 100644 --- a/src/version.c +++ b/src/version.c @@ -776,6 +776,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 1766, /**/ 1765, /**/