I wrote:

I can't see an obvious way around the problem for multi-byte case - lower() then requires converting to and from wchar, and I don't see a way of avoiding calling lower().

There is one way we could reduce the use of lower() by up to (almost) 50% in the common case where the pattern is a constant expression (or a literal, as it usually is) - cache the result of lower() on the pattern rather than call it for every text the pattern is being compared to. I'm not quite sure how to achieve that though.

Anyone have good ideas?



---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?


Reply via email to