RFR: 8316557: Make fields final in 'sun.util' package
Chen Liang
liach at openjdk.org
Tue Sep 19 20:22:06 UTC 2023
On Thu, 14 Sep 2023 08:58:56 GMT, Andrey Turbanov <aturbanov at openjdk.org> wrote:
> A few classes in `sun.util` package have non-final fields which could easily be marked `final`.
src/java.base/share/classes/sun/util/PropertyResourceBundleCharset.java line 71:
> 69: private final class PropertiesFileDecoder extends CharsetDecoder {
> 70:
> 71: private final CharsetDecoder cdUTF_8 = UTF_8.INSTANCE.newDecoder()
Can be static as well.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/15736#discussion_r1328836367
More information about the core-libs-dev
mailing list