1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-11-26 07:33:47 +00:00

(file_name_completion): If completion_ignore_case is enabled, ignore

case when checking completion-regexp-list.
This commit is contained in:
Chong Yidong 2008-11-08 16:55:23 +00:00
parent be70e18348
commit cc524e3b21

View File

@ -631,10 +631,21 @@ file_name_completion (file, dirname, all_flag, ver_flag, predicate)
XSETFASTINT (zero, 0);
/* Ignore this element if it fails to match all the regexps. */
for (regexps = Vcompletion_regexp_list; CONSP (regexps);
regexps = XCDR (regexps))
if (fast_string_match (XCAR (regexps), name) < 0)
break;
if (completion_ignore_case)
{
for (regexps = Vcompletion_regexp_list; CONSP (regexps);
regexps = XCDR (regexps))
if (fast_string_match_ignore_case (XCAR (regexps), name) < 0)
break;
}
else
{
for (regexps = Vcompletion_regexp_list; CONSP (regexps);
regexps = XCDR (regexps))
if (fast_string_match (XCAR (regexps), name) < 0)
break;
}
if (CONSP (regexps))
continue;
}