From: Bram Moolenaar Date: Sat, 11 Aug 2018 12:41:55 +0000 (+0200) Subject: patch 8.1.0270: checking for a Tab in a line could be faster X-Git-Tag: v8.1.0270 X-Git-Url: http://git.ipfire.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=b31a3acce13231643b006988c1ce76b8a12b2982;p=thirdparty%2Fvim.git patch 8.1.0270: checking for a Tab in a line could be faster Problem: Checking for a Tab in a line could be faster. Solution: Use strchr() instead of strrchr(). (closes #3312) --- diff --git a/src/ex_cmds.c b/src/ex_cmds.c index 2c57776404..bee50c5955 100644 --- a/src/ex_cmds.c +++ b/src/ex_cmds.c @@ -281,7 +281,7 @@ linelen(int *has_tab) *last = NUL; len = linetabsize(line); /* get line length */ if (has_tab != NULL) /* check for embedded TAB */ - *has_tab = (vim_strrchr(first, TAB) != NULL); + *has_tab = (vim_strchr(first, TAB) != NULL); *last = save; return len; diff --git a/src/version.c b/src/version.c index da43f60323..d92e7785c1 100644 --- a/src/version.c +++ b/src/version.c @@ -794,6 +794,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 270, /**/ 269, /**/