summaryrefslogtreecommitdiffstats
path: root/dx
diff options
context:
space:
mode:
Diffstat (limited to 'dx')
-rw-r--r--dx/src/com/android/jack/dx/util/IntList.java25
1 files changed, 2 insertions, 23 deletions
diff --git a/dx/src/com/android/jack/dx/util/IntList.java b/dx/src/com/android/jack/dx/util/IntList.java
index 36e96d05..415dea47 100644
--- a/dx/src/com/android/jack/dx/util/IntList.java
+++ b/dx/src/com/android/jack/dx/util/IntList.java
@@ -169,16 +169,7 @@ public final class IntList extends MutabilityControl {
* @return the indicated element's value
*/
public int get(int n) {
- if (n >= size) {
- throw new IndexOutOfBoundsException("n >= size()");
- }
-
- try {
return values[n];
- } catch (ArrayIndexOutOfBoundsException ex) {
- // Translate exception.
- throw new IndexOutOfBoundsException("n < 0");
- }
}
/**
@@ -189,20 +180,8 @@ public final class IntList extends MutabilityControl {
*/
public void set(int n, int value) {
throwIfImmutable();
-
- if (n >= size) {
- throw new IndexOutOfBoundsException("n >= size()");
- }
-
- try {
- values[n] = value;
- sorted = false;
- } catch (ArrayIndexOutOfBoundsException ex) {
- // Translate the exception.
- if (n < 0) {
- throw new IllegalArgumentException("n < 0");
- }
- }
+ values[n] = value;
+ sorted = false;
}
/**