From b61a305039a58ac0c2ff095b22e4eb6d7ccfc89e Mon Sep 17 00:00:00 2001 From: ckelsel Date: Mon, 8 Jan 2018 12:23:33 +0800 Subject: [PATCH] vim-patch:8.0.0351: no test for concatenating an empty string Problem: No test for concatenating an empty string that results from out of bounds indexing. Solution: Add a simple test. https://github.com/vim/vim/commit/218426896cbb2129aa4e85803ea97c5b57df1eaa --- src/nvim/testdir/test_expr.vim | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/nvim/testdir/test_expr.vim b/src/nvim/testdir/test_expr.vim index d32facaa98..ad967c528c 100644 --- a/src/nvim/testdir/test_expr.vim +++ b/src/nvim/testdir/test_expr.vim @@ -439,3 +439,8 @@ func Test_funcref() call assert_equal(2, OneByRef()) call assert_fails('echo funcref("{")', 'E475:') endfunc + +func Test_empty_concatenate() + call assert_equal('b', 'a'[4:0] . 'b') + call assert_equal('b', 'b' . 'a'[4:0]) +endfunc