emacs-devel
[Top][All Lists]
Advanced

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

Re: lexicographic list comparison


From: mattiase
Subject: Re: lexicographic list comparison
Date: Mon, 12 Sep 2022 19:53:42 +0200

12 sep. 2022 kl. 16.45 skrev Sam Steingold <sds@gnu.org>:

> okay, so, I suppose, you find the `lexicographic-compare-lists' from TS
> useful, right?

(What is TS in this context?)
I usually just copy-paste code from an older project of mine (who doesn't?) 
because that way I know that it works, how it works, what its performance is 
like, etc.

> I certainly have no intention of comparing strings with numbers &c.
> My question was about a list of _homogeneous_ lists, and comparing to,
> say, lists of numbers, is done lexicographically based on number
> comparison.

We could certainly add comparison functions for lists, then ones for arrays, 
then for hash tables, and so on. Or just write one that works for all built-in 
types and impose an ordering between objects of distinct types. It would be 
more useful (if harder to write).





reply via email to

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