Problem: Some comments are not correct or clear.
Solution: Adjust the comments. Add test for cursor position.
/*
* Match a regexp against a string ("line" points to the string) or multiple
- * lines ("line" is NULL, use reg_getline()).
+ * lines (if "line" is NULL, use reg_getline()).
* Returns 0 for failure, number of lines contained in the match otherwise.
*/
static long
/*
* Match a regexp against a string ("line" points to the string) or multiple
- * lines ("line" is NULL, use reg_getline()).
+ * lines (if "line" is NULL, use reg_getline()).
*
* Returns <= 0 for failure, number of lines contained in the match otherwise.
*/
-" Test for :execute, :while and :if
+" Test for :execute, :while, :for and :if
-function Test_exec_while_if()
+func Test_exec_while_if()
new
let i = 0
\ "7x999999999888888887777777666666555554444333221",
\ "8",
\ "9x"], getline(1, 10))
-endfunction
+endfunc
" vim: shiftwidth=2 sts=2 expandtab
close!
endfunc
+func Test_substitute_skipped_range()
+ new
+ if 0
+ /1/5/2/2/\n
+ endif
+ call assert_equal([0, 1, 1, 0, 1], getcurpos())
+ bwipe!
+endfunc
+
" vim: shiftwidth=2 sts=2 expandtab
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 2829,
/**/
2828,
/**/