emacs-devel
[Top][All Lists]
Advanced

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

Re: case-insensitive string comparison


From: Sam Steingold
Subject: Re: case-insensitive string comparison
Date: Wed, 20 Jul 2022 12:22:33 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (darwin)

> * Stefan Monnier <zbaavre@veb.hzbagerny.pn> [2022-07-19 23:01:31 -0400]:
>
>> PS. Actually, compare-strings/ignore_case is broken because it does,
>> essentially, upcase both arguments, see 
>> https://stackoverflow.com/q/319426/850781
>
> Hmm... `string-collate-equalp`?

--8<---------------cut here---------------start------------->8---
(string-collate-equalp "a" "A" current-locale-environment t)
==> nil
current-locale-environment
==> "en_US.UTF-8"
--8<---------------cut here---------------end--------------->8---

-- 
Sam Steingold (http://sds.podval.org/) on darwin Ns 10.3.2113
http://childpsy.net http://calmchildstories.com http://steingoldpsychology.com
https://ij.org/ https://memri.org https://honestreporting.com
There are 3 kinds of people: those who can count and those who cannot.



reply via email to

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