Problem: Reading past end of the line when C-indenting.
Solution: Check for NUL.
while (vim_isdigit(p[i - 1])) // '\000'
++i;
}
- if (p[i] == '\'') // check for trailing '
+ if (p[i - 1] != NUL && p[i] == '\'') // check for trailing '
{
p += i;
continue;
close!
endfunc
+" This was reading past the end of the line
+func Test_cindent_check_funcdecl()
+ new
+ sil norm o0\ f('\0\ f=L
+ bwipe!
+endfunc
+
func Test_cindent_scopedecls()
new
setl cindent ts=4 sw=4
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 4968,
/**/
4967,
/**/