From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: mattiase@acm.org Newsgroups: gmane.emacs.devel Subject: Re: lexicographic list comparison Date: Mon, 12 Sep 2022 19:53:42 +0200 Message-ID: References: Mime-Version: 1.0 (Mac OS X Mail 14.0 \(3654.120.0.1.13\)) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="30020"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel To: sds@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Sep 12 19:56:15 2022 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oXnfL-0007fL-CP for ged-emacs-devel@m.gmane-mx.org; Mon, 12 Sep 2022 19:56:15 +0200 Original-Received: from localhost ([::1]:35276 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oXnfK-0002u1-EB for ged-emacs-devel@m.gmane-mx.org; Mon, 12 Sep 2022 13:56:14 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:37942) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oXndF-00011e-5R for emacs-devel@gnu.org; Mon, 12 Sep 2022 13:54:05 -0400 Original-Received: from mail1436c50.megamailservers.eu ([91.136.14.36]:50872 helo=mail263c50.megamailservers.eu) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oXndC-0001To-I9; Mon, 12 Sep 2022 13:54:04 -0400 X-Authenticated-User: mattiase@bredband.net DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=megamailservers.eu; s=maildub; t=1663005225; bh=9G/e1XF2RWm+dZESttI+fyH3vGnIrHfpqNJeoPLcgjk=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From; b=pznmw3triu46ZMJ6u8Sm3rRD/M+yRmGfaovvLebMhH58c4vRnNMxlh6UuZE10czB2 Dh7Tqxlg+5/2pXgFrIEcAFmKJaPdoVPChYSYNR5p3AgYLe1NUdgId8hcwUv05TJmK7 7GE3lW0hOlAUNQr2OZd/VTN19TRw4Kl0NeK7IlSI= Feedback-ID: mattiase@acm.or Original-Received: from smtpclient.apple (c188-150.188-179.bredband.tele2.se [188.150.188.179] (may be forged)) (authenticated bits=0) by mail263c50.megamailservers.eu (8.14.9/8.13.1) with ESMTP id 28CHrhDK075346; Mon, 12 Sep 2022 17:53:45 +0000 In-Reply-To: X-Mailer: Apple Mail (2.3654.120.0.1.13) X-CTCH-RefID: str=0001.0A782F18.631F7229.001F, ss=1, re=0.000, recu=0.000, reip=0.000, cl=1, cld=1, fgs=0 X-CTCH-VOD: Unknown X-CTCH-Spam: Unknown X-CTCH-Score: 0.000 X-CTCH-Flags: 0 X-CTCH-ScoreCust: 0.000 X-Origin-Country: SE Received-SPF: softfail client-ip=91.136.14.36; envelope-from=mattiase@acm.org; helo=mail263c50.megamailservers.eu X-Spam_score_int: -11 X-Spam_score: -1.2 X-Spam_bar: - X-Spam_report: (-1.2 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, SPF_HELO_NONE=0.001, SPF_SOFTFAIL=0.665, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:295213 Archived-At: 12 sep. 2022 kl. 16.45 skrev Sam Steingold : > 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).