diff options
| author | zeertzjq <zeertzjq@outlook.com> | 2022-02-18 10:15:08 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-02-18 10:15:08 +0800 |
| commit | faeff49cbfd190afba67e221412b7132b7ad8360 (patch) | |
| tree | bb6260556f056982e51f6dda99bd882e650cafcc /src/nvim/testdir/test_normal.vim | |
| parent | 592f4a7c0807427355635eb371215036325e5bb8 (diff) | |
| parent | 62a1290758a3cd6af95dc47a3bbdc7dcf290d531 (diff) | |
| download | rneovim-faeff49cbfd190afba67e221412b7132b7ad8360.tar.gz rneovim-faeff49cbfd190afba67e221412b7132b7ad8360.tar.bz2 rneovim-faeff49cbfd190afba67e221412b7132b7ad8360.zip | |
Merge pull request #17449 from zeertzjq/vim-8.2.3659
vim-patch:8.2.{3659,3660,3661}: integer overflow with large line number
Diffstat (limited to 'src/nvim/testdir/test_normal.vim')
| -rw-r--r-- | src/nvim/testdir/test_normal.vim | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_normal.vim b/src/nvim/testdir/test_normal.vim index 5b7cf6fee5..e8eebb3fdd 100644 --- a/src/nvim/testdir/test_normal.vim +++ b/src/nvim/testdir/test_normal.vim @@ -2779,4 +2779,25 @@ func Test_normal_gj_on_extra_wide_char() bw! endfunc +func Test_normal_count_out_of_range() + new + call setline(1, 'text') + normal 44444444444| + call assert_equal(999999999, v:count) + normal 444444444444| + call assert_equal(999999999, v:count) + normal 4444444444444| + call assert_equal(999999999, v:count) + normal 4444444444444444444| + call assert_equal(999999999, v:count) + + normal 9y99999999| + call assert_equal(899999991, v:count) + normal 10y99999999| + call assert_equal(999999999, v:count) + normal 44444444444y44444444444| + call assert_equal(999999999, v:count) + bwipe! +endfunc + " vim: shiftwidth=2 sts=2 expandtab |