serebit
04/14/2021, 5:01 PMCasey Brooks
04/14/2021, 5:04 PMnanodeath
04/14/2021, 5:07 PMnanodeath
04/14/2021, 5:08 PMrandomcat
04/14/2021, 5:08 PMserebit
04/14/2021, 5:08 PMnanodeath
04/14/2021, 5:08 PMcapitalize(Locale)
then?Casey Brooks
04/14/2021, 5:09 PM.capitalize()
is quite invaluable. It seems very strange to remove it rather than creating an overload that accepts a LocaleRobert Jaros
04/14/2021, 5:10 PMserebit
04/14/2021, 5:10 PMserebit
04/14/2021, 5:10 PMrandomcat
04/14/2021, 5:10 PMserebit
04/14/2021, 5:11 PM.capitalized()
, .decapitalized()
. Problem solved.nanodeath
04/14/2021, 5:11 PMrandomcat
04/14/2021, 5:12 PMserebit
04/14/2021, 5:12 PMuppercase
is an adjective, capitalize
is a verb, capitalized
is an adjective.serebit
04/14/2021, 5:12 PMcapitalized
is imperative.randomcat
04/14/2021, 5:12 PMnanodeath
04/14/2021, 5:12 PMnanodeath
04/14/2021, 5:13 PMCasey Brooks
04/14/2021, 5:15 PMnanodeath
04/14/2021, 5:15 PMStatus: Under considerationsomewhat out of date 🙂
serebit
04/14/2021, 5:16 PMnanodeath
04/14/2021, 5:16 PMTo overcome the issue we would like to deprecate the current API and introduce new locale-agnostic functions.this does feel like overstepping to me -- maybe let people make bad decisions
Casey Brooks
04/14/2021, 5:19 PMrandomcat
04/14/2021, 5:19 PMnanodeath
04/14/2021, 5:21 PMthe invariant locale in other Kotlin platforms.I'm similarly confused by this. this just means other platforms don't support locales?
Casey Brooks
04/14/2021, 5:25 PMnanodeath
04/14/2021, 5:26 PMCasey Brooks
04/14/2021, 5:26 PMTo obtain correct results for locale insensitive strings, use toUpperCase(Locale.ROOT).making the API locale agnostic isn’t going to remind users that those functions should only be used on locale-agnostic text. It’s just going to be abused in the same way as the current functions
nanodeath
04/14/2021, 5:26 PMrandomcat
04/14/2021, 5:27 PMrandomcat
04/14/2021, 5:27 PMnanodeath
04/14/2021, 5:28 PMJustin Tullgren
04/14/2021, 5:40 PMJustin Tullgren
04/14/2021, 5:44 PMfun String.toCapitalized(): String = replaceFirstChar { /*default*/ }
Justin Tullgren
04/14/2021, 5:45 PMnanodeath
04/14/2021, 5:46 PMJustin Tullgren
04/14/2021, 5:47 PMJustin Tullgren
04/14/2021, 5:47 PMOliver.O
04/14/2021, 8:39 PMOliver.O
04/14/2021, 8:42 PM