5 ms·
Changes to the casing might also change the value's length. E.g. uppercasing the German ß will transform it to SS. Example using JavaScript: 'ß'.toUpperCase();
by FrontAid 6y ago
Changes to the casing might also change the value's length. E.g. uppercasing the German ß will transform it to SS. Example using JavaScript:
'ß'.toUpperCase(); // returns 'SS'
https://en.wikipedia.org/wiki/%C3%9F https://en.wikipedia.org/wiki/%C3%9F
- schoen 6y agoThere is apparently a multi-decade controversy about that: https://en.wikipedia.org/wiki/Capital_%E1%BA%9E https://en.wikipedia.org/wiki/Capital_%E1%BA%9E (with German language authorities recently endorsing the idea that ß can have a distinctive uppercase form "ẞ")
- deleted 6y ago[deleted]
- dathinab 6y agoWhich can be both correct and wrong depending on context. Normally there is no such thing as a capital ß, so it was decided that if for some unreasonable reason you do uppercase it you go with SS. But then for some all-caps usages this is not right. E.g. a all caps name of an restaurant as placed above the restaurants door. In which case it was common to have a ß in a all-caps name like FOOßBAR. So they decided that for reasons like this we now have an (EDIT: semi?) official uppercase ß. So all in all this and other examples in other languages mean you should never do a case insensitive comparison by upper/lower casing both sides, it won't work reliable.