RFR: 8336755: Remove unused UNALIGNED field from Direct non-byte Buffers
Chen Liang
liach at openjdk.org
Thu Jul 18 15:50:01 UTC 2024
On Thu, 18 Jul 2024 12:21:39 GMT, Andrey Turbanov <aturbanov at openjdk.org> wrote:
>> src/java.base/share/classes/java/nio/Direct-X-Buffer.java.template line 70:
>>
>>> 68: #if[byte]
>>> 69: // Cached unaligned-access capability
>>> 70: protected static final boolean UNALIGNED = Bits.unaligned();
>>
>> Can you drop the protected modifier and check that it builds?
>
> Yes, it builds when I drop modifier.
>
> // Cached unaligned-access capability
> static final boolean UNALIGNED = Bits.unaligned();
Indeed, we should remove the protected modifier in a package-private class.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/20233#discussion_r1682748975
More information about the nio-dev
mailing list