RFR (M): 8135250: Replace custom check/range functionality with check index/range methods in java.util.Arrays

Paul Sandoz paul.sandoz at oracle.com
Thu Jan 7 08:15:42 UTC 2016

Hi Kishor,

Looks good to me. A small but nice improvement.

I guess you are ok with these throwing IndexOutOfBounds rather than ArrayIndexOutOfBounds.


Note that i am going to revisit the exception message reporting and with nudging by John the BiFunction to ensure no bounds information is lost. It should not affect this code, but should produce better error messages, and after it might be an opportunity to revisit if you want these to throw ArrayIndexOutOfBounds.


> On 7 Jan 2016, at 01:18, Kharbas, Kishor <kishor.kharbas at intel.com> wrote:
> Hello all,
> Requesting the community to review a patch which replaces custom bound checking functionality with calls to methods in java.util.Objects.
> The methods affected are CounterMode.crypt() and AESCrypt.encryptBlock(), AESCrypt.decryptBlock()
> Bug id:
>  https://bugs.openjdk.java.net/browse/JDK-8135250
> Webrev:
>  http://cr.openjdk.java.net/~vdeshpande/8135250/webrev.00/
> Regards
> Kishor Kharbas

More information about the core-libs-dev mailing list