File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
main/java/com/ibm/icu/text
test/java/com/ibm/icu/dev/test/rbbi Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -524,12 +524,12 @@ public int preceding(int offset) {
524
524
525
525
526
526
/**
527
- * Throw IllegalArgumentException unless begin <= offset < end.
527
+ * Throw IndexOutOfBoundsException unless begin <= offset < end.
528
528
* @stable ICU 2.0
529
529
*/
530
530
protected static final void checkOffset (int offset , CharacterIterator text ) {
531
531
if (offset < text .getBeginIndex () || offset > text .getEndIndex ()) {
532
- throw new IllegalArgumentException ("offset out of bounds" );
532
+ throw new IndexOutOfBoundsException ("offset out of bounds" );
533
533
}
534
534
}
535
535
Original file line number Diff line number Diff line change @@ -158,7 +158,7 @@ public void TestBug4153072() {
158
158
errln ("Didn't get exception with offset = " + index +
159
159
" and begin index = " + begin );
160
160
}
161
- catch (IllegalArgumentException e ) {
161
+ catch (IndexOutOfBoundsException e ) {
162
162
if (index >= begin )
163
163
errln ("Got exception with offset = " + index +
164
164
" and begin index = " + begin );
You can’t perform that action at this time.
0 commit comments