3 ms·
According to my (admittedly limited) understamding of Unicode, they did almost everything correctly. The only issue I see is with the 'uppercase'/'lowercase' fu
by tomp 11y ago
According to my (admittedly limited) understamding of Unicode, they did almost everything correctly. The only issue I see is with the 'uppercase'/'lowercase' functions, which use algorithms that depend on locale; I wonder which locale Swift assumes (hopefully not some global one...).
- cballard 11y agoThose are (or were, at least) bridged from NSString. There's a bunch of path handling stuff available as well, because Swift String can be converted to and from NSString.
- Cyberdog 11y agoYou can use the lowercaseStringWithLocale/uppercaseStringWithLocale methods to explicitly specify which locale to use: https://developer.apple.com/library/ios/documentation/Cocoa/Reference/Foundation/Classes/NSString_Class/index.html#//apple_ref/occ/instm/NSString/uppercaseStringWithLocale https://developer.apple.com/library/ios/documentation/Cocoa/...: