1
0
forked from aniani/vim

patch 7.4.941

Problem:    There is no way to ignore case only for tag searches.
Solution:   Add the 'tagcase' option. (Gary Johnson)
This commit is contained in:
Bram Moolenaar
2015-11-24 18:48:14 +01:00
parent 2a1b474fd8
commit 0f6562e903
20 changed files with 254 additions and 24 deletions

View File

@@ -1385,6 +1385,18 @@ find_tags(pat, num_matches, matchesp, flags, mincount, buf_ffname)
int use_cscope = (flags & TAG_CSCOPE);
#endif
int verbose = (flags & TAG_VERBOSE);
int save_p_ic = p_ic;
/*
* Change the value of 'ignorecase' according to 'tagcase' for the
* duration of this function.
*/
switch (curbuf->b_tc_flags ? curbuf->b_tc_flags : tc_flags)
{
case TC_FOLLOWIC: break;
case TC_IGNORE: p_ic = TRUE; break;
case TC_MATCH: p_ic = FALSE; break;
}
help_save = curbuf->b_help;
orgpat.pat = pat;
@@ -2552,6 +2564,8 @@ findtag_end:
vim_free(saved_pat);
#endif
p_ic = save_p_ic;
return retval;
}