summaryrefslogtreecommitdiff
path: root/core/java/android/util/SparseLongArray.java
diff options
context:
space:
mode:
authorPaul Scovanner <pscovanner@google.com>2019-03-12 18:03:48 +0000
committerPaul Scovanner <pscovanner@google.com>2019-03-12 18:03:48 +0000
commit91ec97056451753d6db55d310fc93fbd93c61cb3 (patch)
treef9e0ae0442395fe2c7c6ab74c350dd939943d1dc /core/java/android/util/SparseLongArray.java
parent17d453ea85703a5bc26c0669231be4d6f0d8bbac (diff)
Revert "Checkng upper bound in *Array classes."
This reverts commit 17d453ea85703a5bc26c0669231be4d6f0d8bbac. Reason for revert: b/127750694 Change-Id: I0ffbf0e64109b3ec724e0687a27b231e335f76b4
Diffstat (limited to 'core/java/android/util/SparseLongArray.java')
-rw-r--r--core/java/android/util/SparseLongArray.java8
1 files changed, 0 insertions, 8 deletions
diff --git a/core/java/android/util/SparseLongArray.java b/core/java/android/util/SparseLongArray.java
index 37a92024f374..81db2b7ff715 100644
--- a/core/java/android/util/SparseLongArray.java
+++ b/core/java/android/util/SparseLongArray.java
@@ -182,10 +182,6 @@ public class SparseLongArray implements Cloneable {
* key.</p>
*/
public int keyAt(int index) {
- if (index >= mSize) {
- // The array might be slightly bigger than mSize, in which case, indexing won't fail.
- throw new ArrayIndexOutOfBoundsException(index);
- }
return mKeys[index];
}
@@ -201,10 +197,6 @@ public class SparseLongArray implements Cloneable {
* associated with the largest key.</p>
*/
public long valueAt(int index) {
- if (index >= mSize) {
- // The array might be slightly bigger than mSize, in which case, indexing won't fail.
- throw new ArrayIndexOutOfBoundsException(index);
- }
return mValues[index];
}