Permalink
Browse files

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.
  • Loading branch information...
brammool committed Feb 23, 2017
1 parent ae177b7 commit 218426896cbb2129aa4e85803ea97c5b57df1eaa
Showing with 7 additions and 0 deletions.
  1. +5 −0 src/testdir/test_expr.vim
  2. +2 −0 src/version.c
@@ -473,3 +473,8 @@ func Test_setmatches()
call setmatches(set)
call assert_equal(exp, getmatches())
endfunc
+
+func Test_empty_concatenate()
+ call assert_equal('b', 'a'[4:0] . 'b')
+ call assert_equal('b', 'b' . 'a'[4:0])
+endfunc
View
@@ -764,6 +764,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 351,
/**/
350,
/**/

0 comments on commit 2184268

Please sign in to comment.