Major performance problem with std.array.front()
monarch_dodra
monarchdodra at gmail.com
Sun Mar 9 12:13:48 PDT 2014
On Sunday, 9 March 2014 at 14:57:32 UTC, Peter Alexander wrote:
> You have mentioned case-insensitive searching, but I think I've
> adequately demonstrated that this doesn't work in general by
> code point: you need to normalize and take locales into account.
I don't understand what your argument. Is it "by code point is
not 100% correct, so let's just drop it and go for raw code units
instead?"
We *are* arguing about whether or not "front/popFront" should
decode by dchar, right...?
You mention the algorithms "Searching, equality testing, copying,
sorting, hashing, splitting, joining..." I said "by codepoint is
not correct", but I still think it's a hell of a lot more
accurate than by codeunit. Unless you want to ignore any and all
algorithms that takes a predicate?
You say "unless you are willing to ignore languages like
Turkish", but... If you don't decode front, than aren't you just
ignoring *all* languages that basically aren't English....?
As I said, maybe by codepoint is not correct, but if it isn't, I
think we should be moving further *into* the correct behavior by
default, not away from it.
More information about the Digitalmars-d
mailing list