From: Junio C Hamano Date: Wed, 18 Jan 2023 16:20:20 GMT Subject: Re: [PATCH v3] grep: correctly identify utf-8 characters with \{b,w} in -P Message-ID: In-Reply-To: <230118.86tu0ovyvj.gmgdl@evledraar.gmail.com> Ævar Arnfjörð Bjarmason writes: >> GNU grep -P has no knob and would likely never have one. > > I think the general knob in not just GNU grep but GNU utils and the > wider *nix landscape is "tweak your LC_ALL and/or other locale > varibales". > > Which works for it, and will work for us once we're using PCRE2_UCP too. > >> So for now, I think we should acknowledge the bug, provide an option >> for people that might need the fix, and fix all other problems we >> have, which will include changes in PCRE2 as well to better fit our >> use case. > > Hrm, what are those PCRE2 changes? The one I saw so far (or was it a > proposal) was to just make its "grep" utility use the PCRE2_UCP like GNU > grep is now doing in its unreleased version in its git repo... Yeah, I didn't understand Carlo's comment in that paragraph at all. In short, it sounds to me that the earlier one that added PCRE2_UCP unconditionally would be the best alternative among those that have been discussed.