RFR: 8361299: (bf) CharBuffer.getChars(int,int,char[],int) violates pre-existing specification [v3]
Alan Bateman
alanb at openjdk.org
Thu Jul 3 09:46:40 UTC 2025
On Thu, 3 Jul 2025 00:33:58 GMT, Brian Burkhalter <bpb at openjdk.org> wrote:
>> Modify `CharBuffer.getChars` to respect the class level specification that the provided buffer offset `srcBegin` is relative to the buffer's current position.
>
> Brian Burkhalter has updated the pull request incrementally with one additional commit since the last revision:
>
> 8361299: Ensure [srcBegin,srcEnd) is contained in [0,limit()-position())
test/jdk/java/nio/Buffer/GetChars.java line 75:
> 73:
> 74: @Test
> 75: public void testSrcBeginIsNegationOfPosition() {
I skimmed through GetChars and I see it only tests a CB created with CharBuffer.wrap. I think we change each of these tests to changed to paramterrized tests that test all implementations.
-------------
PR Review Comment: https://git.openjdk.org/jdk/pull/26104#discussion_r2182346032
More information about the nio-dev
mailing list