8219876: (bf) Improve IndexOutOfBoundsException messages in $Type$Buffer classes

Alan Bateman Alan.Bateman at oracle.com
Thu Feb 28 07:57:38 UTC 2019


On 27/02/2019 21:48, Brian Burkhalter wrote:
> For the issue [1], please review the patch [2] which would replace the package-scope method java.nio.Buffer.checkBounds(offset,count,bound) with java.util.Objects.checkFromIndexSize(offset,count,bound) [3]. The latter method would provide more detail on the IOOBE if it should occur.
>
I assume you'll run benchmarks and/or look at the generated code to make 
sure that the checks inline as expected. Otherwise looks good.

-Alan.


More information about the nio-dev mailing list