emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Human-readable file sorting


From: Eli Zaretskii
Subject: Re: Human-readable file sorting
Date: Sat, 20 Feb 2016 14:35:23 +0200

> From: Lars Ingebrigtsen <address@hidden>
> Cc: address@hidden
> Date: Sat, 20 Feb 2016 22:45:31 +1100
> 
> Eli Zaretskii <address@hidden> writes:
> 
> >> > Please don't call that function `file-string-lessp', or anything that
> >> > has "file" in it.  This sorting order has nothing to do with files.
> >> 
> >> Well, this is the function that's supposed to sort file names in the
> >> order requested by the user
> >
> > I think it's supposed to sort strings while treating numeric parts of
> > them specially.  Its usage domain is wider than just file names.
> 
> No no.  This is the function that all Emacs things that want to sort
> file names should use.  

It's okay to sort file names using a comparison function that can be
used with strings that are not file names.  But if you call it
"file-SOMETHING", then it will look weird if someone uses it to sort
strings that are not file names.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]