diff --git a/src/nvim/testdir/Makefile b/src/nvim/testdir/Makefile index 59c93f1673..bca18adef8 100644 --- a/src/nvim/testdir/Makefile +++ b/src/nvim/testdir/Makefile @@ -37,6 +37,7 @@ NEW_TESTS = \ test_hardcopy.res \ test_help_tagjump.res \ test_history.res \ + test_increment_dbcs.res \ test_langmap.res \ test_match.res \ test_matchadd_conceal.res \ diff --git a/src/nvim/testdir/test_increment_dbcs.vim b/src/nvim/testdir/test_increment_dbcs.vim new file mode 100644 index 0000000000..ee286a0a24 --- /dev/null +++ b/src/nvim/testdir/test_increment_dbcs.vim @@ -0,0 +1,29 @@ +" Tests for using Ctrl-A/Ctrl-X using DBCS. +if !has('multi_byte') + finish +endif +scriptencoding cp932 + +func SetUp() + new + set nrformats& +endfunc + +func TearDown() + bwipe! +endfunc + +func Test_increment_dbcs_1() + set nrformats+=alpha + call setline(1, ["ŽR1"]) + exec "norm! 0\" + call assert_equal(["ŽR2"], getline(1, '$')) + call assert_equal([0, 1, 4, 0], getpos('.')) + + call setline(1, ["‚`‚a‚b0xDE‚e"]) + exec "norm! 0\" + call assert_equal(["‚`‚a‚b0xDD‚e"], getline(1, '$')) + call assert_equal([0, 1, 13, 0], getpos('.')) +endfunc + +" vim: shiftwidth=2 expandtab diff --git a/src/nvim/version.c b/src/nvim/version.c index a958ff1fd9..d62ecc22cf 100644 --- a/src/nvim/version.c +++ b/src/nvim/version.c @@ -486,7 +486,7 @@ static int included_patches[] = { // 1957 NA 1956, // 1955 NA - // 1954, + 1954, 1953, 1952, // 1951 NA