▲ | mikestew 17 hours ago | |||||||||||||
When I saw "Turkish alphabet bug", I just knew it was some version of toLower() gone horribly wrong. (I'm sure there's a good reason, but I find it odd that compiler message tags are invariably uppercase, but in this problem code they lowercased it to go do a lookup from an enum of lowercase names. Why isn't the enum uppercase, like the things you're going to lookup?) | ||||||||||||||
▲ | kevin_thibedeau 14 hours ago | parent | next [-] | |||||||||||||
With Turkish you can't safely case-fold with toupper() or tolower() in a C/US locale: i->I and I->i are both wrong. Uppercasing wouldn't work. You have to use Unicode or Latin-5 to manage it. | ||||||||||||||
| ||||||||||||||
▲ | kokada 6 hours ago | parent | prev | next [-] | |||||||||||||
Without looking at the source code I think it is because the log functions are lowercase, but I am not sure this is the reason. | ||||||||||||||
▲ | thaumasiotes 15 hours ago | parent | prev [-] | |||||||||||||
> Why isn't the enum uppercase, like the things you're going to lookup? Another question: why does the log record the string you intended to look up, instead of the string you actually did look up? |