RFR: 8255150: Add utility methods to check long indexes and ranges [v2]
Jorn Vernee
jvernee at openjdk.java.net
Thu Nov 5 16:47:56 UTC 2020
On Thu, 5 Nov 2020 15:42:54 GMT, Roland Westrelin <roland at openjdk.org> wrote:
>> src/java.base/share/classes/java/lang/IndexOutOfBoundsException.java line 83:
>>
>>> 81: */
>>> 82: public IndexOutOfBoundsException(long index) {
>>> 83: super("Index out of range: " + index);
>>
>> For consistency with the class name:
>> Suggestion:
>>
>> super("Index out of bounds: " + index);
>
> Not sure about that one as it's a copy of the message from IndexOutOfBoundsException(int index). Both would need to be changed for consistency.
Ok, I didn't notice that it was taken from elsewhere. Never mind then.
-------------
PR: https://git.openjdk.java.net/jdk/pull/1003
More information about the core-libs-dev
mailing list