From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: case-insensitive string comparison Date: Wed, 20 Jul 2022 21:16:12 +0300 Message-ID: <83czdzlker.fsf@gnu.org> References: <87ilnsq4cr.fsf@gnu.org> <87mtd3n455.fsf@gnu.org> <83ilnrlnd1.fsf@gnu.org> <87lesnlm7a.fsf@gnu.org> <83fsivlllz.fsf@gnu.org> <8735evlko4.fsf@gnu.org> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="37621"; mail-complaints-to="usenet@ciao.gmane.io" Cc: monnier@iro.umontreal.ca, emacs-devel@gnu.org To: Roland Winkler Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Jul 20 20:17:01 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 1oEEFo-0009VG-S1 for ged-emacs-devel@m.gmane-mx.org; Wed, 20 Jul 2022 20:17:01 +0200 Original-Received: from localhost ([::1]:34242 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1oEEFm-000649-F5 for ged-emacs-devel@m.gmane-mx.org; Wed, 20 Jul 2022 14:16:59 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:47624) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oEEFC-0005Nq-Dv for emacs-devel@gnu.org; Wed, 20 Jul 2022 14:16:22 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]:35032) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oEEFC-0000Qe-58; Wed, 20 Jul 2022 14:16:22 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=gxp6D8ITDGrFuRg3Yg0I4ZnRo/fFoG1fb/7hpWTGSa8=; b=H8dwFD/qs2iN f146wzFKpYk4CnOVq6ka6lswfxMHmdBefJoHtNCTV/yhXdxFRhrb/ie1P9giqsFTQ+Ez13XIhf3Wl EoZQeWgBYgaZHeLe//VdeGA+HRjus59se4EIPbzB2PceFlTXdbB10BYqQYME2dnSjRHvztgQJS4ED KvYC59PtIijhRIp9o1mnUMSMmN2sY4nAzoAEvaSuBDzQCj0fdI1WGxX2jX9eV5IBfId+FfcS7M4kk 55/PA7fPve6yL/TqPO3TyMB/3N7mCG+cUTuSbfCQk4avsUXjpHT0hqALvo2OQvtUdNrkwQQRd1NIB stS37YRzWHzVbNKro0T3kw==; Original-Received: from [87.69.77.57] (port=2375 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oEEFA-0005m2-GA; Wed, 20 Jul 2022 14:16:21 -0400 In-Reply-To: <8735evlko4.fsf@gnu.org> (message from Roland Winkler on Wed, 20 Jul 2022 13:10:35 -0500) 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:292316 Archived-At: > From: Roland Winkler > Cc: monnier@iro.umontreal.ca, emacs-devel@gnu.org > Date: Wed, 20 Jul 2022 13:10:35 -0500 > > On Wed, Jul 20 2022, Eli Zaretskii wrote: > >> Even mentioning the difficulties could be useful here. > > > > I'm not sure I agree. To describe all the important aspects of this > > would take too long, and it isn't the job of our manual to document > > this stuff. Read this if you want to know: > > > > https://unicode.org/reports/tr10/ > > A footnote pointing the interested reader to this report could already > be useful. I'll see if we have a good place for that. > > Not the users should build the case table, BBDB (or whatever Lisp > > program that needs the comparison) should. It's not that hard, > > really: if you only need ASCII, use ascii-case-table, otherwise copy > > the standard case-table and modify it to make sure I downcases to i > > and similarly with a few other exceptional letters. > > I am not sure it would be possible to predict how a default case table > for BBDB should differ from the standard case table. BBDB might be the > only package of a user that accumulates strings that go beyond what > otherwise a user is dealing with regularly. If there is a sensible > "BBDB default case table" I'd hope that this is the standard case table. Maybe BBDB can just use the standard case table, I don't know. You should be the judge of that: if your users don't care with I not being equal to i case-insensitively, when the language-environment happens to be Turkish, then you shouldn't worry about that. > Or if not: can you suggest an emacs package that I can look into as a > source of inspiration? I'm not aware of any (which is not to say there isn't any, just that I don't know).