summaryrefslogtreecommitdiff
path: root/src/dired.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/dired.c')
-rw-r--r--src/dired.c35
1 files changed, 20 insertions, 15 deletions
diff --git a/src/dired.c b/src/dired.c
index cd50012ddc7..e31ad9121c9 100644
--- a/src/dired.c
+++ b/src/dired.c
@@ -521,9 +521,9 @@ file_name_completion (Lisp_Object file, Lisp_Object dirname, bool all_flag,
name = DECODE_FILE (name);
ptrdiff_t name_blen = SBYTES (name), name_len = SCHARS (name);
if (completion_ignore_case
- && !EQ (Fcompare_strings (name, zero, file_len, file, zero, file_len,
- Qt),
- Qt))
+ && !BASE_EQ (Fcompare_strings (name, zero, file_len, file, zero,
+ file_len, Qt),
+ Qt))
continue;
switch (dirent_type (dp))
@@ -603,10 +603,12 @@ file_name_completion (Lisp_Object file, Lisp_Object dirname, bool all_flag,
skip = name_len - elt_len;
cmp_len = make_fixnum (elt_len);
if (skip < 0
- || !EQ (Fcompare_strings (name, make_fixnum (skip),
- Qnil,
- elt, zero, cmp_len, Qt),
- Qt))
+ || !BASE_EQ (Fcompare_strings (name,
+ make_fixnum (skip),
+ Qnil,
+ elt, zero, cmp_len,
+ Qt),
+ Qt))
continue;
}
break;
@@ -637,10 +639,12 @@ file_name_completion (Lisp_Object file, Lisp_Object dirname, bool all_flag,
skip = name_len - elt_len;
cmp_len = make_fixnum (elt_len);
if (skip < 0
- || !EQ (Fcompare_strings (name, make_fixnum (skip),
- Qnil,
- elt, zero, cmp_len, Qt),
- Qt))
+ || !BASE_EQ (Fcompare_strings (name,
+ make_fixnum (skip),
+ Qnil,
+ elt, zero, cmp_len,
+ Qt),
+ Qt))
continue;
}
break;
@@ -699,7 +703,7 @@ file_name_completion (Lisp_Object file, Lisp_Object dirname, bool all_flag,
= Fcompare_strings (name, zero, make_fixnum (compare),
file, zero, make_fixnum (compare),
completion_ignore_case ? Qt : Qnil);
- if (!EQ (cmp, Qt))
+ if (!BASE_EQ (cmp, Qt))
continue;
}
@@ -722,7 +726,8 @@ file_name_completion (Lisp_Object file, Lisp_Object dirname, bool all_flag,
= Fcompare_strings (bestmatch, zero, make_fixnum (compare),
name, zero, make_fixnum (compare),
completion_ignore_case ? Qt : Qnil);
- ptrdiff_t matchsize = EQ (cmp, Qt) ? compare : eabs (XFIXNUM (cmp)) - 1;
+ ptrdiff_t matchsize = BASE_EQ (cmp, Qt)
+ ? compare : eabs (XFIXNUM (cmp)) - 1;
if (completion_ignore_case)
{
@@ -751,13 +756,13 @@ file_name_completion (Lisp_Object file, Lisp_Object dirname, bool all_flag,
file, zero,
Qnil,
Qnil),
- EQ (Qt, cmp))
+ BASE_EQ (Qt, cmp))
&& (cmp = Fcompare_strings (bestmatch, zero,
make_fixnum (SCHARS (file)),
file, zero,
Qnil,
Qnil),
- ! EQ (Qt, cmp))))
+ ! BASE_EQ (Qt, cmp))))
bestmatch = name;
}
bestmatchsize = matchsize;