> From: "Glavo" <zjx001...@gmail.com>
> To: "core-libs-dev" <core-libs-dev@openjdk.org>
> Sent: Tuesday, April 11, 2023 10:02:01 PM
> Subject: Draft: Deprecate toLowerCase()/toUpperCase() and provide locale
> insensitive alternative

> Hi everyone,

> A few months ago, I discussed in this mailing list[1] whether
> toLowerCase()/toUpperCase() should be deprecated.
> At that time, I received some approval and no one opposed the idea. 
> Therefore, I
> thought it might be time
> to continue advancing this work, so I created a PR[2] for this.

> This PR is still a draft, welcome to discuss it there.

> I don't have much experience in contributing to OpenJDK yet, so I also hope to
> get the help of experienced
> contributors (such as creating CSR). Thanks!

I think deprecating toLowerCase()/toUpperCase() is a great idea but at the same 
time, i'm not sure that the methods lowercase() and uppercase() are a good 
addition. 
Their names are too close to toLowerCase/toUpperCase thus too easy to misuse 
ones for the others. 

I'm fine with users having to write toLowerCase(Locale.ROOT) or 
toUpperCase(Locale.Root) because this is already what we teach. 

> Glavo

regards, 
Rémi 

> [1] [ 
> https://mail.openjdk.org/pipermail/core-libs-dev/2023-January/099375.html
> | https://mail.openjdk.org/pipermail/core-libs-dev/2023-January/099375.html ]
> [2] [ https://github.com/openjdk/jdk/pull/13434 |
> https://github.com/openjdk/jdk/pull/13434 ]

Reply via email to